Commit 7722f6d2 authored by Alex Brainman's avatar Alex Brainman

cmd/go: keep WINDIR during TestScript

TestScript executes PowerShell. And PowerShell appears to require
WINDIR environment variable to exists on windows-arm.

So keep WINDIR environment variable when running PowerShell.

Fixes #30711

Change-Id: I14dde6614347325a8f3caf994ea8ab05294450a5
Reviewed-on: https://go-review.googlesource.com/c/go/+/168859
Run-TryBot: Alex Brainman <alex.brainman@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: default avatarBrad Fitzpatrick <bradfitz@golang.org>
parent e770b5b3
...@@ -84,6 +84,7 @@ type backgroundCmd struct { ...@@ -84,6 +84,7 @@ type backgroundCmd struct {
var extraEnvKeys = []string{ var extraEnvKeys = []string{
"SYSTEMROOT", // must be preserved on Windows to find DLLs; golang.org/issue/25210 "SYSTEMROOT", // must be preserved on Windows to find DLLs; golang.org/issue/25210
"WINDIR", // must be preserved on Windows to be able to run PowerShell command; golang.org/issue/30711
"LD_LIBRARY_PATH", // must be preserved on Unix systems to find shared libraries "LD_LIBRARY_PATH", // must be preserved on Unix systems to find shared libraries
"CC", // don't lose user settings when invoking cgo "CC", // don't lose user settings when invoking cgo
"GO_TESTING_GOTOOLS", // for gccgo testing "GO_TESTING_GOTOOLS", // for gccgo testing
......
[!windows] stop [!windows] stop
[arm] skip # TODO(golang.org/issue/30711): Skip broken test.
[!exec:icacls] skip [!exec:icacls] skip
[!exec:powershell] skip [!exec:powershell] skip
......
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