Skip to content

Commit ca33b34

Browse files
committed
runtime: deflake TestPreemptionAfterSyscall
This test occasionally takes very slightly longer than the 3 second timeout on slow builders (especially windows-386-2008), so increase the timeout to 5 seconds. It fails with much longer timeouts on Plan 9, so skip it as flaky there. Updates #41015. Change-Id: I426a7adfae92c18a0f8a223dd92762b0b91565e1 Reviewed-on: https://go-review.googlesource.com/c/go/+/379214 Trust: Austin Clements <[email protected]> Reviewed-by: Cherry Mui <[email protected]> Reviewed-by: Bryan Mills <[email protected]>
1 parent 2a061fd commit ca33b34

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/runtime/proc_test.go

+5-1
Original file line numberDiff line numberDiff line change
@@ -1044,7 +1044,7 @@ func testPreemptionAfterSyscall(t *testing.T, syscallDuration time.Duration) {
10441044
interations = 1
10451045
}
10461046
const (
1047-
maxDuration = 3 * time.Second
1047+
maxDuration = 5 * time.Second
10481048
nroutines = 8
10491049
)
10501050

@@ -1080,6 +1080,10 @@ func testPreemptionAfterSyscall(t *testing.T, syscallDuration time.Duration) {
10801080
}
10811081

10821082
func TestPreemptionAfterSyscall(t *testing.T) {
1083+
if runtime.GOOS == "plan9" {
1084+
testenv.SkipFlaky(t, 41015)
1085+
}
1086+
10831087
for _, i := range []time.Duration{10, 100, 1000} {
10841088
d := i * time.Microsecond
10851089
t.Run(fmt.Sprint(d), func(t *testing.T) {

0 commit comments

Comments
 (0)