You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The go test command now automatically runs go vet on the package being tested, to identify significant problems before running the test. Any such problems are treated like build errors and prevent execution of the test. Only a high-confidence subset of the available go vet checks are enabled for this automatic check. To disable the running of go vet, use go test -vet=off.
That kind of buries the lede: the fact that it only runs a subset by default is important, especially since some of the checks that are not currently enabled detect significant errors (see #24112).
I'm not sure whether it's too late to revise the release notes, but it might be clearer to move that information up front:
The go test command now automatically runs a high-confidence subset of go vet checks on the package being tested, to identify significant problems before running the test. Any such problems are treated like build errors and prevent execution of the test. To disable the running of go vet, use go test -vet off.
It would also be helpful to document how to add more flags to the default set, or whether that's even possible. (If I run go test -vet all, is that expected to do the right thing?)
Go 1.10 enables a subset of vet commands during test.
I could not find which commands where implemented without going to the source:
go/src/cmd/go/internal/test/test.go
Lines 509 to 533 in 438a757
It would be nice to have these in
go help test
.The text was updated successfully, but these errors were encountered: