1
0
mirror of https://github.com/golang/go synced 2024-10-04 13:21:22 -06:00
Commit Graph

8 Commits

Author SHA1 Message Date
Brad Fitzpatrick
b4bc7b44ae time: deflake TestAfterQueuing
Ramp up the delay on subsequent attempts. Fast builders have the same delay.

Not a perfect fix, but should make it better. And this easy.

Fixes #9903 maybe
Fixes #10680 maybe

Change-Id: I967380c2cb8196e6da9a71116961229d37b36335
Reviewed-on: https://go-review.googlesource.com/9795
Reviewed-by: Matthew Dempsky <mdempsky@google.com>
2015-05-06 19:26:27 +00:00
Keith Randall
e2e322d293 time: Fix ordering of slots in AfterQueueing test
We shouldn't sort the slots array, as it is used each time the
test is run.  Tests after the first should continue to use the
unsorted ordering.

Note that this doesn't fix the flaky test.  Just a bug I saw
while investigating.

Change-Id: Ic03cca637829d569d50d3a2278d19410d4dedba9
Reviewed-on: https://go-review.googlesource.com/9637
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2015-05-04 16:49:37 +00:00
Matthew Dempsky
d12b532265 time: use longer delta duration for TestAfterQueueing retries
The TestAfterQueueing test is inherently flaky because it relies on
independent kernel threads being scheduled within the "delta" duration
of each other.  Normally, delta is 100ms but during "short" testing,
it's reduced to 20ms.

On at least OpenBSD, the CPU scheduler operates in 10ms time slices,
so high system load (e.g., from running multiple Go unit tests in
parallel, as happens during all.bash) can occasionally cause >20ms
scheduling delays and result in test flaking.  This manifests as issue
9903, which is the currently the most common OpenBSD flake.

To mitigate this delay, only reduce the delta duration to 20ms for the
first attempt during short testing.  If this fails and the test is
reattempted, subsequent attempts instead use a full 100ms delta.

Fixes #9903.

Change-Id: I11bdfa939e5be915f67ffad8a8aef6ed8772159a
Reviewed-on: https://go-review.googlesource.com/9510
Run-TryBot: Matthew Dempsky <mdempsky@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
2015-04-29 21:43:29 +00:00
David Crawshaw
ce1c9247b0 time: zoneinfo support for darwin
Roll forward of 54efdc596f. Better testing of the build on
darwin/amd64. There is still some variance between cmd/dist
and the Go tool for build tag handling.

Change-Id: I105669ae7f90c8c89b3839c04b182cff46be8dde
Reviewed-on: https://go-review.googlesource.com/6516
Run-TryBot: David Crawshaw <crawshaw@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Hyang-Ah Hana Kim <hyangah@gmail.com>
2015-03-03 15:37:14 +00:00
David Crawshaw
31336f9c11 Revert "time: zoneinfo support on darwin/arm"
This reverts commit 54efdc596f.

Broken on darwin.

Change-Id: Ic74275f36d30975263340e2b4045226eae71b16a
Reviewed-on: https://go-review.googlesource.com/6514
Reviewed-by: David Crawshaw <crawshaw@golang.org>
2015-03-03 02:37:30 +00:00
David Crawshaw
54efdc596f time: zoneinfo support on darwin/arm
A future change will include an NSTimeZone hook so we can determine
the device's current time zone.

Change-Id: Ia4bd6b955e4cb720c518055541b66ff57a4dd303
Reviewed-on: https://go-review.googlesource.com/6511
Reviewed-by: Hyang-Ah Hana Kim <hyangah@gmail.com>
Run-TryBot: David Crawshaw <crawshaw@golang.org>
2015-03-03 02:24:34 +00:00
Brad Fitzpatrick
ab4af52a9b time: panic with a more helpful error on use of invalid Timer
Fixes #8721

LGTM=rsc
R=r, rsc
CC=golang-codereviews
https://golang.org/cl/155620045
2014-10-21 13:26:40 +02:00
Russ Cox
c007ce824d build: move package sources from src/pkg to src
Preparation was in CL 134570043.
This CL contains only the effect of 'hg mv src/pkg/* src'.
For more about the move, see golang.org/s/go14nopkg.
2014-09-08 00:08:51 -04:00