all: disable some tests that take a long time or allocate a lot of memory. --- src/encoding/gob/encoder_test.go +++ src/encoding/gob/encoder_test.go @@ -1003,10 +1003,7 @@ func TestBadData(t *testing.T) { // TestHugeWriteFails tests that enormous messages trigger an error. func TestHugeWriteFails(t *testing.T) { - if testing.Short() { - // Requires allocating a monster, so don't do this from all.bash. - t.Skip("skipping huge allocation in short mode") - } + t.Skip("skipping test due to huge memory requirement") huge := make([]byte, tooBig) huge[0] = 7 // Make sure it's not all zeros. buf := new(bytes.Buffer) --- src/math/big/float_test.go +++ src/math/big/float_test.go @@ -1428,10 +1428,7 @@ func TestFloatQuo(t *testing.T) { // TestFloatQuoSmoke tests all divisions x/y for values x, y in the range [-n, +n]; // it serves as a smoke test for basic correctness of division. func TestFloatQuoSmoke(t *testing.T) { - n := 1000 - if testing.Short() { - n = 10 - } + n := 10 const dprec = 3 // max. precision variation const prec = 10 + dprec // enough bits to hold n precisely --- src/math/big/rat_test.go +++ src/math/big/rat_test.go @@ -430,10 +430,7 @@ func TestFloat64Distribution(t *testing.T) { 9, 11, } - var winc, einc = uint64(1), 1 // soak test (~75s on x86-64) - if testing.Short() { - winc, einc = 10, 500 // quick test (~12ms on x86-64) - } + var winc, einc = uint64(10), 500 for _, sign := range "+-" { for _, a := range add { --- src/math/big/ratconv_test.go +++ src/math/big/ratconv_test.go @@ -344,9 +344,7 @@ func isFinite(f float64) bool { func TestFloat32SpecialCases(t *testing.T) { for _, input := range float64inputs { if strings.HasPrefix(input, "long:") { - if testing.Short() { - continue - } + continue input = input[len("long:"):] } @@ -400,9 +398,7 @@ func TestFloat32SpecialCases(t *testing.T) { func TestFloat64SpecialCases(t *testing.T) { for _, input := range float64inputs { if strings.HasPrefix(input, "long:") { - if testing.Short() { - continue - } + continue input = input[len("long:"):] } --- src/net/dial_test.go +++ src/net/dial_test.go @@ -77,10 +77,7 @@ func TestSelfConnect(t *testing.T) { l.Close() // Try to connect to that address repeatedly. - n := 100000 - if testing.Short() { - n = 1000 - } + n := 1000 switch runtime.GOOS { case "darwin", "dragonfly", "freebsd", "netbsd", "openbsd", "plan9", "solaris", "windows": // Non-Linux systems take a long time to figure --- src/runtime/fastlog2_test.go +++ src/runtime/fastlog2_test.go @@ -16,11 +16,7 @@ func TestFastLog2(t *testing.T) { const randomBitCount = 26 var e float64 - inc := 1 - if testing.Short() { - // Check 1K total values, down from 64M. - inc = 1 << 16 - } + inc := 1 << 16 for i := 1; i < 1<