summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBryan C. Mills <bcmills@google.com>2020-11-05 15:11:09 -0500
committerBryan C. Mills <bcmills@google.com>2020-11-09 17:38:50 +0000
commita6462a608d60b6175db9dd9a7244b9609a12e7fc (patch)
tree919baf18bf9ad1f9ad9725d1fbbf7a53db32091d
parenta07e4360a80b3ff2490879e4b4065ecc7b1b9098 (diff)
downloadgo-git-a6462a608d60b6175db9dd9a7244b9609a12e7fc.tar.gz
cmd/go: set FOSSIL_HOME in TestScript/mod_get_fossil
Without HOME or FOSSIL_HOME set, this test fails for me when run with fossil 2.12.1. Also verify that the 'go get' command produces an executable, which helps to verify that the files extracted by fossil are not corrupted. Updates #42323 Change-Id: Ie6f5d2eab6a6338e997a4f85591195e5bd9a0d37 Reviewed-on: https://go-review.googlesource.com/c/go/+/267884 Trust: Bryan C. Mills <bcmills@google.com> Run-TryBot: Bryan C. Mills <bcmills@google.com> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Jay Conrod <jayconrod@google.com>
-rw-r--r--src/cmd/go/testdata/script/mod_get_fossil.txt5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/cmd/go/testdata/script/mod_get_fossil.txt b/src/cmd/go/testdata/script/mod_get_fossil.txt
index 3482e68da1..baad544557 100644
--- a/src/cmd/go/testdata/script/mod_get_fossil.txt
+++ b/src/cmd/go/testdata/script/mod_get_fossil.txt
@@ -13,14 +13,17 @@ env GOSUMDB=off
# 'go get' for the fossil repo will fail if fossil
# is unable to determine your fossil user. Easiest
-# way to set it for use by 'go get' is specifying
+# way to set it for use by 'go get' is specifying
# a any non-empty $USER; the value doesn't otherwise matter.
env USER=fossiluser
+env FOSSIL_HOME=$WORK/home
# Attempting to get the latest version of a fossil repo.
go get vcs-test.golang.org/fossil/hello.fossil
! stderr 'unexpected response from fossil info'
grep 'vcs-test.golang.org/fossil/hello.fossil' go.mod
+exists $GOPATH/bin/hello.fossil$GOEXE
-- go.mod --
module x
+-- $WORK/home/.fossil --