xprintf("Building packages and commands for target, %s/%s.\n", goos, goarch)
}
targets := []string{"std", "cmd"}
- if goos == "js" && goarch == "wasm" {
- // Skip the cmd tools for js/wasm. They're not usable.
- targets = targets[:1]
- }
goInstall(goBootstrap, targets...)
checkNotStale(goBootstrap, targets...)
checkNotStale(cmdGo, targets...)
// Instead, we can just check that it is not stale, which may be less
// expensive (and is also more likely to catch bugs in the builder
// implementation).
- willTest := []string{"std"}
- if t.shouldTestCmd() {
- willTest = append(willTest, "cmd")
- }
- checkNotStale("go", willTest...)
+ checkNotStale("go", "std", "cmd")
}
}
if t.race {
cmd.Args = append(cmd.Args, "-tags=race")
}
- cmd.Args = append(cmd.Args, "std")
- if t.shouldTestCmd() {
- cmd.Args = append(cmd.Args, "cmd")
- }
+ cmd.Args = append(cmd.Args, "std", "cmd")
cmd.Stderr = new(bytes.Buffer)
all, err := cmd.Output()
if err != nil {
return err == nil
}
-func (t *tester) shouldTestCmd() bool {
- if goos == "js" && goarch == "wasm" {
- // Issues 25911, 35220
- return false
- }
- return true
-}
-
// prebuiltGoPackageTestBinary returns the path where we'd expect
// the pre-built go test binary to be on disk when dist test is run with
// a single argument.