diff options
| author | Russ Cox <rsc@golang.org> | 2015-07-15 01:16:47 -0400 |
|---|---|---|
| committer | Russ Cox <rsc@golang.org> | 2015-07-15 05:23:35 +0000 |
| commit | 5a4cc600b79075d8ad6304809c70a7d94da628cd (patch) | |
| tree | 2daee4c643022c35d7394e02772d974917dbdefb /src | |
| parent | 47f22ab77557b41c918894e004a78dc5952ea58a (diff) | |
| download | go-5a4cc600b79075d8ad6304809c70a7d94da628cd.tar.xz | |
cmd/go: fix nocgo builder
Change-Id: I0f167d9769d9b6b9888c13fcb48e538fc87aa1b7
Reviewed-on: https://go-review.googlesource.com/12240
Reviewed-by: Russ Cox <rsc@golang.org>
Diffstat (limited to 'src')
| -rw-r--r-- | src/cmd/go/go_test.go | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/cmd/go/go_test.go b/src/cmd/go/go_test.go index 8af8ab6cc3..67f2534c7f 100644 --- a/src/cmd/go/go_test.go +++ b/src/cmd/go/go_test.go @@ -8,6 +8,7 @@ import ( "bytes" "flag" "fmt" + "go/build" "go/format" "internal/testenv" "io/ioutil" @@ -2106,6 +2107,10 @@ func TestGoTestRaceInstallCgo(t *testing.T) { t.Skip("no race detector on %s", sys) } + if !build.Default.CgoEnabled { + t.Skip("no race detector without cgo") + } + // golang.org/issue/10500. // This used to install a race-enabled cgo. tg := testgo(t) |
