]> Cypherpunks repositories - gostls13.git/commitdiff
cmd/go/testdata/script: remove skips and clarify comments in mod_*_upgrade_pseudo...
authorBryan C. Mills <bcmills@google.com>
Fri, 10 May 2019 15:10:50 +0000 (11:10 -0400)
committerBryan C. Mills <bcmills@google.com>
Fri, 10 May 2019 15:38:01 +0000 (15:38 +0000)
These tests were added in CL 174206.

They required a 'git' binary and network access in an earlier draft,
but now use the test-local module proxy instead, so no longer need to
be skipped when those resources are not present.

Updates #30634

Change-Id: I5f36c6c776209a89bc45d133847df5052b55da59
Reviewed-on: https://go-review.googlesource.com/c/go/+/176537
Run-TryBot: Bryan C. Mills <bcmills@google.com>
Reviewed-by: Jay Conrod <jayconrod@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>

src/cmd/go/testdata/script/mod_get_upgrade_pseudo.txt
src/cmd/go/testdata/script/mod_list_upgrade_pseudo.txt

index 69acea57bbcf2faa87a0ccdb668fc5912a1caf8f..80b240130fdd4366b01f60d05e5492a27aee1084 100644 (file)
@@ -1,19 +1,14 @@
 env GO111MODULE=on
 
-# Testing that a pseudo version with schematically higher version than the latest
-# tagged version isn't downgraded when running 'go get -u'.
+# For this test module there are three versions:
+#   * v0.1.1-0.20190429073117-b5426c86b553
+#   * v0.1.0
+#   * v0.0.0-20190429073000-30950c05d534
+# Only v0.1.0 is tagged.
+#
+# The latest pseudo-version is semantically higher than the latest tag.
+# 'get -u' should not downgrade to the (lower) tagged version.
 
-[!net] skip
-[!exec:git] skip
-
-# For this test repository there are three commits:
-#   * b5426c8 "master" (v0.1.1-0.20190429073117-b5426c86b553)
-#   * a90cfd2 (tag: v0.1.0)
-#   * 30950c0
-
-# When requesting master as specific version, a pseudo version is created with a
-# higher version than the latest tag. Running 'go get -u' doesn't downgrade the
-# version.
 go get -m example.com/pseudoupgrade@b5426c8
 go get -u
 go list -m -u all
index 6935e03d6edadb6eab1b0af9f1f51f6a27f5881c..143e029e52139eed4791db2356f244b5ee37fbcf 100644 (file)
@@ -1,19 +1,14 @@
 env GO111MODULE=on
 
-# Testing that a pseudo version with schematically higher version than the latest
-# tagged version isn't listed as upgradable when calling 'go list -m -u'.
+# For this test module there are three versions:
+#   * v0.1.1-0.20190429073117-b5426c86b553
+#   * v0.1.0
+#   * v0.0.0-20190429073000-30950c05d534
+# Only v0.1.0 is tagged.
+#
+# The latest pseudo-version is semantically higher than the latest tag.
+# 'list -u' should not suggest a lower version as an upgrade.
 
-[!net] skip
-[!exec:git] skip
-
-# For this test repository there are three commits:
-#   * b5426c8 "master" (v0.1.1-0.20190429073117-b5426c86b553)
-#   * a90cfd2 (tag: v0.1.0)
-#   * 30950c0
-
-# When requesting master as specific version, a pseudo version is created with a
-# higher version than the latest tag. Listing upgrades doesn't suggest the lower
-# version as upgrade.
 go get -m example.com/pseudoupgrade@b5426c8
 go list -m -u all
 stdout '^example.com/pseudoupgrade v0.1.1-0.20190429073117-b5426c86b553$'