mirror of https://github.com/golang/go.git
go/build: set GO111MODULE=off explicitly in TestImportVendor*
These tests check for GOPATH-mode vendoring behavior, so make sure they're in GOPATH mode. Updates #30228 Change-Id: I646f59b67cb76dacd07adc3f6ed15ed63f4e22a4 Reviewed-on: https://go-review.googlesource.com/c/164620 Run-TryBot: Bryan C. Mills <bcmills@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Jay Conrod <jayconrod@google.com>
This commit is contained in:
parent
4f4c2a79d4
commit
4e10ce45f5
|
|
@ -350,6 +350,10 @@ func TestImportDirNotExist(t *testing.T) {
|
|||
|
||||
func TestImportVendor(t *testing.T) {
|
||||
testenv.MustHaveGoBuild(t) // really must just have source
|
||||
|
||||
defer os.Setenv("GO111MODULE", os.Getenv("GO111MODULE"))
|
||||
os.Setenv("GO111MODULE", "off")
|
||||
|
||||
ctxt := Default
|
||||
wd, err := os.Getwd()
|
||||
if err != nil {
|
||||
|
|
@ -368,6 +372,10 @@ func TestImportVendor(t *testing.T) {
|
|||
|
||||
func TestImportVendorFailure(t *testing.T) {
|
||||
testenv.MustHaveGoBuild(t) // really must just have source
|
||||
|
||||
defer os.Setenv("GO111MODULE", os.Getenv("GO111MODULE"))
|
||||
os.Setenv("GO111MODULE", "off")
|
||||
|
||||
ctxt := Default
|
||||
wd, err := os.Getwd()
|
||||
if err != nil {
|
||||
|
|
@ -387,6 +395,10 @@ func TestImportVendorFailure(t *testing.T) {
|
|||
|
||||
func TestImportVendorParentFailure(t *testing.T) {
|
||||
testenv.MustHaveGoBuild(t) // really must just have source
|
||||
|
||||
defer os.Setenv("GO111MODULE", os.Getenv("GO111MODULE"))
|
||||
os.Setenv("GO111MODULE", "off")
|
||||
|
||||
ctxt := Default
|
||||
wd, err := os.Getwd()
|
||||
if err != nil {
|
||||
|
|
|
|||
Loading…
Reference in New Issue