Skip to content

Commit 03f58a3

Browse files
committed
all: skip slow tests in short mode
Updates golang/go#14113 Updates golang/go#11811 Change-Id: I61851de12ff474d3b738fc88f402742677973cae
1 parent 09dc3ef commit 03f58a3

File tree

3 files changed

+12
-0
lines changed

3 files changed

+12
-0
lines changed

go/loader/stdlib_test.go

+6
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,9 @@ func TestStdlib(t *testing.T) {
3232
if runtime.GOOS == "android" {
3333
t.Skipf("incomplete std lib on %s", runtime.GOOS)
3434
}
35+
if testing.Short() {
36+
t.Skip("skipping in short mode; uses tons of memory (golang.org/issue/14113)")
37+
}
3538

3639
runtime.GC()
3740
t0 := time.Now()
@@ -118,6 +121,9 @@ func TestStdlib(t *testing.T) {
118121
}
119122

120123
func TestCgoOption(t *testing.T) {
124+
if testing.Short() {
125+
t.Skip("skipping in short mode; uses tons of memory (golang.org/issue/14113)")
126+
}
121127
switch runtime.GOOS {
122128
// On these systems, the net and os/user packages don't use cgo
123129
// or the std library is incomplete (Android).

go/pointer/pointer_test.go

+3
Original file line numberDiff line numberDiff line change
@@ -522,6 +522,9 @@ func checkWarningExpectation(prog *ssa.Program, e *expectation, warnings []point
522522
}
523523

524524
func TestInput(t *testing.T) {
525+
if testing.Short() {
526+
t.Skip("skipping in short mode; this test requires tons of memory; golang.org/issue/14113")
527+
}
525528
ok := true
526529

527530
wd, err := os.Getwd()

go/ssa/stdlib_test.go

+3
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,9 @@ func bytesAllocated() uint64 {
4747
}
4848

4949
func TestStdlib(t *testing.T) {
50+
if testing.Short() {
51+
t.Skip("skipping in short mode; too slow (golang.org/issue/14113)")
52+
}
5053
// Load, parse and type-check the program.
5154
t0 := time.Now()
5255
alloc0 := bytesAllocated()

0 commit comments

Comments
 (0)