Merge pull request #12127 from spowelljr/fixSkaffoldTets

Fix `TestSkaffold` on Windows
pull/12131/head
Medya Ghazizadeh 2021-08-05 01:20:49 -07:00 committed by GitHub
commit 1eebdca5bd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 1 deletions

View File

@ -81,7 +81,11 @@ func TestSkaffold(t *testing.T) {
}
oldPath := os.Getenv("PATH")
os.Setenv("PATH", fmt.Sprintf("%s:%s", filepath.Dir(abs), os.Getenv("PATH")))
pathSeparator := ":"
if runtime.GOOS == "windows" {
pathSeparator = ";"
}
os.Setenv("PATH", fmt.Sprintf("%s%s%s", filepath.Dir(abs), pathSeparator, os.Getenv("PATH")))
// make sure 'docker' and 'minikube' are now in PATH
for _, binary := range []string{"minikube", "docker"} {