New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cmd/go: unavailable vcs fails test #26837

iWdGo opened this Issue Aug 7, 2018 · 2 comments


None yet
4 participants

iWdGo commented Aug 7, 2018

Please answer these questions before submitting your issue. Thanks!

What version of Go are you using (go version)?

go version go1.11beta3 windows/amd64

Does this issue reproduce with the latest release?


What operating system and processor architecture are you using (go env)? Yes

set GOARCH=amd64
set GOBIN=
set GOCACHE=C:\Users\()\AppData\Local\go-build
set GOEXE=.exe
set GOHOSTARCH=amd64
set GOHOSTOS=windows
set GOOS=windows
set GOPATH=C:\Users\()\Documents\Google\
set GOROOT=C:\Go
set GOTOOLDIR=C:\Go\pkg\tool\windows_amd64
set GCCGO=gccgo
set CC=gcc
set CXX=g++
set GOMOD=
set CGO_CFLAGS=-g -O2
set CGO_FFLAGS=-g -O2
set CGO_LDFLAGS=-g -O2
set PKG_CONFIG=pkg-config
set GOGCCFLAGS=-m64 -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=C:\Users\()\AppData\Local\Temp\go-build152074326=/tmp/go-build -gno-record-gcc-switches

What did you do?

c:\Users\()\Documents\Google\golang\go\src>go test -run=TestMove -v cmd/go

If possible, provide a recipe for reproducing the error.
A complete runnable program is good.
A link on is best.

What did you expect to see?

c:\Users\Costa\Documents\Google\golang\go\src>go test -run=TestMove -v cmd/go
=== RUN   TestMoveGit
=== PAUSE TestMoveGit
=== RUN   TestMoveHG
=== PAUSE TestMoveHG
=== CONT  TestMoveGit
=== CONT  TestMoveHG
--- SKIP: TestMoveHG (1.39s)
--- PASS: TestMoveGit (34.37s)
    (same test output)
PASS    cmd/go  46.407s

What did you see instead?

c:\Users\Costa\Documents\Google\golang\go\src>go test -run=TestMove -v cmd/go
=== RUN   TestMoveGit
=== PAUSE TestMoveGit
=== RUN   TestMoveHG
=== PAUSE TestMoveHG
=== CONT  TestMoveGit
=== CONT  TestMoveHG
--- FAIL: TestMoveHG (7.39s)
    go_test.go:1079: running testgo [get -d]
    go_test.go:1079: standard error:
    go_test.go:1079: go: missing Mercurial command. See
        package exec: "hg": executable file not found in %PATH%

    go_test.go:1079: go [get -d] failed unexpectedly in C:\Go\src\cmd\go: exit status 1
--- PASS: TestMoveGit (34.37s)
    go_test.go:1079: running testgo [get -d]
    go_test.go:1080: running testgo [get -d -u]
    go_test.go:1102: running testgo [build -o sink.exe sink]
    go_test.go:1105: running testgo [get -d -u]
    go_test.go:1105: standard error:
    go_test.go:1105: package is a custom import path for, but C:\Users\Costa\AppData\Local\Temp\gotest245418038\src\\pdf is checked out from

    go_test.go:1105: testgo failed as expected: exit status 1
    go_test.go:1107: running testgo [get -d -f -u]
    go_test.go:1107: standard error:
    go_test.go:1107: # cd C:\Users\Costa\AppData\Local\Temp\gotest245418038\src\\pdf; git pull --ff-only
        remote: Repository not found.
        fatal: repository '' not found
        package exit status 1

    go_test.go:1107: testgo failed as expected: exit status 1
FAIL    cmd/go  46.407s

The test fails as one vcs (Mercurial in the example) is unavailable. Test should be skipped with the usual warning when vcs is unavailable. As a side remark, cmd/go tests are timing out after 10 minutes. As tests run in parallel as 'PAUSED" until all tests are listed as per output above, such errors never appear in short mode.


This comment has been minimized.

gopherbot commented Aug 7, 2018

Change mentions this issue: cmd/go: skip test when vcs is unavailable

@bcmills bcmills added the NeedsFix label Aug 9, 2018

@bcmills bcmills added this to the Go1.11 milestone Aug 9, 2018

@bcmills bcmills added the Testing label Aug 9, 2018

@rsc rsc modified the milestones: Go1.11, Go1.12 Aug 10, 2018


This comment has been minimized.


bcmills commented Nov 15, 2018

Assigned to @iWdGo, since a fix is pending in

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment