From a5a46e49893a882e8d921e4839e6dde6a9c94536 Mon Sep 17 00:00:00 2001 From: Alexander Neumann Date: Thu, 30 Aug 2018 23:12:15 +0200 Subject: [PATCH] Travis: don't use GOPATH for Go >= 1.11 --- run_integration_tests.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/run_integration_tests.go b/run_integration_tests.go index 364f501cb..c8f316fce 100644 --- a/run_integration_tests.go +++ b/run_integration_tests.go @@ -314,7 +314,6 @@ func (env *TravisEnvironment) RunTests() error { } env.env["RESTIC_TEST_DISALLOW_SKIP"] = strings.Join(ensureTests, ",") - env.env["GOPROXY"] = "off" if *runCrossCompile { // compile for all target architectures with tags @@ -335,6 +334,9 @@ func (env *TravisEnvironment) RunTests() error { msg("Detected Go version %v\n", v) if v.AtLeast(GoVersion{1, 11, 0}) { args = []string{"go", "run", "-mod=vendor", "build.go"} + env.env["GOPROXY"] = "off" + delete(env.env, "GOPATH") + os.Unsetenv("GOPATH") } // run the build script