]> Cypherpunks repositories - gostls13.git/commit
cmd/go/internal/modfetch/codehost: initialize localGitURL lazily and clean up skips
authorBryan C. Mills <bcmills@google.com>
Tue, 2 May 2023 16:44:40 +0000 (12:44 -0400)
committerBryan Mills <bcmills@google.com>
Thu, 4 May 2023 16:24:04 +0000 (16:24 +0000)
commit09a24a91b5aff200aa5fb8e75977c5a354702089
treee7074b7062469859ec341376e894e3f4af467754
parentdcd1c3103295c9f3251ac1eb45e1c585127476fd
cmd/go/internal/modfetch/codehost: initialize localGitURL lazily and clean up skips

Previously localGitURL was initialized in TestMain, which creates
needless work if the test flags do not result in running a test that
requires localGitURL.

We had also been skipping a bunch of tests that used
vcs-test.golang.org in order to avoid network traffic, but now that
that content is served through an in-process vcweb server that is no
longer necessary. (All of the 'git' tests together take less than a
second to run.)

The 'hg' tests are much slower, so we do still skip those in short
mode.

Updates #59940.

Change-Id: Ie4f2d2bc825d7a011e25e754edf1a7c3c6010c77
Reviewed-on: https://go-review.googlesource.com/c/go/+/491659
Reviewed-by: Michael Matloob <matloob@golang.org>
Auto-Submit: Bryan Mills <bcmills@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Run-TryBot: Bryan Mills <bcmills@google.com>
src/cmd/go/internal/modfetch/codehost/git_test.go