]> Cypherpunks.ru repositories - gostls13.git/commitdiff
runtime: use testenv.Command in TestG0StackOverflow
authorCherry Mui <cherryyz@google.com>
Tue, 31 Oct 2023 20:26:52 +0000 (16:26 -0400)
committerCherry Mui <cherryyz@google.com>
Tue, 31 Oct 2023 20:50:47 +0000 (20:50 +0000)
For debugging timeouts.

Change-Id: I08dc86ec0264196e5fd54066655e94a9d062ed80
Reviewed-on: https://go-review.googlesource.com/c/go/+/538697
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Bryan Mills <bcmills@google.com>
src/runtime/crash_test.go

index 7a3b0388d74c9984b000d45d969fdeba46fc84ff..8aa01f724d7b517639b0afa9b709dd90c76f1f51 100644 (file)
@@ -797,7 +797,7 @@ func TestG0StackOverflow(t *testing.T) {
        }
 
        if os.Getenv("TEST_G0_STACK_OVERFLOW") != "1" {
-               cmd := testenv.CleanCmdEnv(exec.Command(os.Args[0], "-test.run=^TestG0StackOverflow$", "-test.v"))
+               cmd := testenv.CleanCmdEnv(testenv.Command(t, os.Args[0], "-test.run=^TestG0StackOverflow$", "-test.v"))
                cmd.Env = append(cmd.Env, "TEST_G0_STACK_OVERFLOW=1")
                out, err := cmd.CombinedOutput()
                // Don't check err since it's expected to crash.