mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
cmd/go/internal/modfetch: remove references to Fetcher_ in test file
This commit removes references to the global Fetcher_ variable from the zip sum test file. Change-Id: I622587f7809f4c6bcd4afbb35312912149b7a3ea Reviewed-on: https://go-review.googlesource.com/c/go/+/724244 Reviewed-by: Michael Matloob <matloob@google.com> LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com> Reviewed-by: Michael Matloob <matloob@golang.org>
This commit is contained in:
parent
da31fd4177
commit
03f499ec46
1 changed files with 2 additions and 1 deletions
|
|
@ -112,6 +112,7 @@ func TestZipSums(t *testing.T) {
|
|||
// Download modules with a rate limit. We may run out of file descriptors
|
||||
// or cause timeouts without a limit.
|
||||
needUpdate := false
|
||||
fetcher := modfetch.NewFetcher()
|
||||
for i := range tests {
|
||||
test := &tests[i]
|
||||
name := fmt.Sprintf("%s@%s", strings.ReplaceAll(test.m.Path, "/", "_"), test.m.Version)
|
||||
|
|
@ -119,7 +120,7 @@ func TestZipSums(t *testing.T) {
|
|||
t.Parallel()
|
||||
ctx := context.Background()
|
||||
|
||||
zipPath, err := modfetch.Fetcher_.DownloadZip(ctx, test.m)
|
||||
zipPath, err := fetcher.DownloadZip(ctx, test.m)
|
||||
if err != nil {
|
||||
if *updateTestData {
|
||||
t.Logf("%s: could not download module: %s (will remove from testdata)", test.m, err)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue