From 9c1b769d5fdd419bbaf416bc51981f0ba2af0831 Mon Sep 17 00:00:00 2001 From: "Bryan C. Mills" Date: Fri, 16 Apr 2021 17:06:02 -0400 Subject: [PATCH] cmd/go: add a source file in the multiple-paths module in TestScript/mod_tidy_replace MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit This situation is analogous to CL 309334: the test expects 'go mod tidy' to fail due to a module used for more than one path in the build list, but doesn't actually contain any packages or imports — so no module is necessarily used at all, and the error only occurs if we report it prematurely. For #36460 Change-Id: I5ccecf30f280895eba913a8d62571872b75e710d Reviewed-on: https://go-review.googlesource.com/c/go/+/312098 Trust: Bryan C. Mills Run-TryBot: Bryan C. Mills TryBot-Result: Go Bot Reviewed-by: Michael Matloob --- src/cmd/go/testdata/script/mod_tidy_replace.txt | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/cmd/go/testdata/script/mod_tidy_replace.txt b/src/cmd/go/testdata/script/mod_tidy_replace.txt index dd99438891..297f6a6a45 100644 --- a/src/cmd/go/testdata/script/mod_tidy_replace.txt +++ b/src/cmd/go/testdata/script/mod_tidy_replace.txt @@ -136,3 +136,10 @@ require ( ) replace not-rsc.io/quote/v3 => rsc.io/quote/v3 v3.0.0 +-- multiple-paths/use.go -- +package quoter + +import ( + _ "not-rsc.io/quote/v3" + _ "rsc.io/quote/v3" +) -- 2.50.0