From: Santiago Vila Subject: Skip TestParallel on single-CPU systems Bug-Debian: https://bugs.debian.org/1102313 --- a/td/t_struct_test.go +++ b/td/t_struct_test.go @@ -8,6 +8,7 @@ import ( "regexp" + "runtime" "strings" "sync" "testing" @@ -136,6 +137,10 @@ // in parallel. We use a WaitGroup to make both subtests block // until they're both ready. This test will block forever if // the tests are not run together. + if runtime.GOMAXPROCS(0) < 2 { + tt.Skip("not enough CPUs to run parallel tests") + } + var ready sync.WaitGroup ready.Add(2)