]> Cypherpunks repositories - gostls13.git/commitdiff
misc/cgo/testshared: unset GOBIN during test
authorIan Lance Taylor <iant@golang.org>
Sun, 12 Jul 2015 17:18:32 +0000 (10:18 -0700)
committerIan Lance Taylor <iant@golang.org>
Sun, 12 Jul 2015 18:06:34 +0000 (18:06 +0000)
Fixes #11273.

Change-Id: I409b6c4168711913076439036d65e8639ca3b06f
Reviewed-on: https://go-review.googlesource.com/12073
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
misc/cgo/testshared/shared_test.go

index 232ca3394aa767bb03dc283dfd8cf0f18db27827..6ef448c4f2759417fb632009f8d85f3478b75291 100644 (file)
@@ -143,6 +143,10 @@ func testMain(m *testing.M) (int, error) {
 }
 
 func TestMain(m *testing.M) {
+       // Some of the tests install binaries into a custom GOPATH.
+       // That won't work if GOBIN is set.
+       os.Unsetenv("GOBIN")
+
        flag.Parse()
        exitCode, err := testMain(m)
        if err != nil {