mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
runtime: skip TestPingPongHog in race mode
TestPingPongHog tests properties of the scheduler. But the race detector intentionally does randomized scheduling, so the test is not applicable. Fixes #38266 Change-Id: Ib06aa317b2776cb1faa641c4e038e2599cf70b2d Reviewed-on: https://go-review.googlesource.com/c/go/+/227344 Run-TryBot: Josh Bleecher Snyder <josharian@gmail.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org>
This commit is contained in:
parent
4874835232
commit
97711bfd60
1 changed files with 6 additions and 0 deletions
|
|
@ -6,6 +6,7 @@ package runtime_test
|
|||
|
||||
import (
|
||||
"fmt"
|
||||
"internal/race"
|
||||
"math"
|
||||
"net"
|
||||
"runtime"
|
||||
|
|
@ -422,6 +423,11 @@ func TestPingPongHog(t *testing.T) {
|
|||
if testing.Short() {
|
||||
t.Skip("skipping in -short mode")
|
||||
}
|
||||
if race.Enabled {
|
||||
// The race detector randomizes the scheduler,
|
||||
// which causes this test to fail (#38266).
|
||||
t.Skip("skipping in -race mode")
|
||||
}
|
||||
|
||||
defer runtime.GOMAXPROCS(runtime.GOMAXPROCS(1))
|
||||
done := make(chan bool)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue