blob: 42526247f1e7e62a67222911d01390d648569609 [file] [log] [blame]
env GO111MODULE=on
[short] skip
# Check that 'go version' and 'go version -m' work on a binary built in module mode.
go build -o fortune.exe
go version fortune.exe
stdout '^fortune.exe: .+'
go version -m fortune.exe
stdout '^\tpath\'
stdout '^\tmod\\tv1.0.0'
# Repeat the test with -buildmode=pie.
# TODO( don't skip after -buildmode=pie is implemented
# on Windows.
[windows] skip # -buildmode=pie not supported
go build -buildmode=pie -o external.exe
go version external.exe
stdout '^external.exe: .+'
go version -m external.exe
stdout '^\tpath\'
stdout '^\tmod\\tv1.0.0'
-- go.mod --
module m