Skip to content

Commit

Permalink
[release-branch.go1.9] runtime: deflake TestPeriodicGC
Browse files Browse the repository at this point in the history
It was only waiting 0.1 seconds for the two GCs it wanted.
Let it wait 1 second.

Change-Id: Ib3cdc8127cbf95694a9f173643c02529a85063af
Reviewed-on: https://go-review.googlesource.com/68118
Run-TryBot: Russ Cox <rsc@golang.org>
Reviewed-by: Chris Broadfoot <cbro@golang.org>
Reviewed-by: Austin Clements <austin@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
  • Loading branch information
rsc committed Oct 4, 2017
1 parent c8aec40 commit d9e6491
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/runtime/gc_test.go
Expand Up @@ -170,7 +170,7 @@ func TestPeriodicGC(t *testing.T) {
// slack if things are slow.
var numGCs uint32
const want = 2
for i := 0; i < 20 && numGCs < want; i++ {
for i := 0; i < 200 && numGCs < want; i++ {
time.Sleep(5 * time.Millisecond)

// Test that periodic GC actually happened.
Expand Down

0 comments on commit d9e6491

Please sign in to comment.