Commit f9e9412c authored by Josh Bleecher Snyder's avatar Josh Bleecher Snyder Committed by Brad Fitzpatrick

cmd/dist: run vet/all on dedicated builders

We will soon add dedicated builders for running vet/all.
Their name will end with "-vetall".
On those builders, run vet/all and nothing else.
On all other builders, including local all.bash,
don't run vet/all at all, because it is slow.

This will probably be refined more over time.

Change-Id: Ib1d0337adda84353931a325515c132068d4320cd
Reviewed-on: https://go-review.googlesource.com/28962
Run-TryBot: Josh Bleecher Snyder <josharian@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: default avatarBrad Fitzpatrick <bradfitz@golang.org>
parent fb273fc3
...@@ -329,6 +329,21 @@ func (t *tester) registerRaceBenchTest(pkg string) { ...@@ -329,6 +329,21 @@ func (t *tester) registerRaceBenchTest(pkg string) {
} }
func (t *tester) registerTests() { func (t *tester) registerTests() {
if strings.HasSuffix(os.Getenv("GO_BUILDER_NAME"), "-vetall") {
// Run vet over std and cmd and call it quits.
t.tests = append(t.tests, distTest{
name: "vet/all",
heading: "go vet std cmd",
fn: func(dt *distTest) error {
// This runs vet/all for the current platform.
// TODO: on a fast builder or builders, run over all platforms.
t.addCmd(dt, "src/cmd/vet/all", "go", "run", "main.go", "-all")
return nil
},
})
return
}
// Fast path to avoid the ~1 second of `go list std cmd` when // Fast path to avoid the ~1 second of `go list std cmd` when
// the caller lists specific tests to run. (as the continuous // the caller lists specific tests to run. (as the continuous
// build coordinator does). // build coordinator does).
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment