]> Cypherpunks repositories - gostls13.git/commitdiff
os/signal: deflake test
authorDmitriy Vyukov <dvyukov@google.com>
Mon, 11 Mar 2013 18:31:34 +0000 (22:31 +0400)
committerDmitriy Vyukov <dvyukov@google.com>
Mon, 11 Mar 2013 18:31:34 +0000 (22:31 +0400)
Fixes #4987.

R=golang-dev, iant
CC=golang-dev
https://golang.org/cl/7713043

src/pkg/os/signal/signal_test.go

index 509b273aa2ff866e63189104f49a6b1af3c10a34..93e5ab9fad1ca6a223f40c2f9802721e99b5377e 100644 (file)
@@ -98,4 +98,8 @@ func TestStress(t *testing.T) {
        close(done)
        <-finished
        <-finished
+       // When run with 'go test -cpu=1,2,4' SIGUSR1 from this test can slip
+       // into subsequent TestSignal() causing failure.
+       // Sleep for a while to reduce the possibility of the failure.
+       time.Sleep(10 * time.Millisecond)
 }