Commit e4791066 authored by David Crawshaw's avatar David Crawshaw

os/exec: disable tests on darwin/arm

There is only one process under the iOS sandboxd.

Change-Id: I21b5528366a0248a034801a717f24c60f0733c5f
Reviewed-on: https://go-review.googlesource.com/6101Reviewed-by: default avatarHyang-Ah Hana Kim <hyangah@gmail.com>
Reviewed-by: default avatarBrad Fitzpatrick <bradfitz@golang.org>
parent 1e0e2ffb
...@@ -28,8 +28,9 @@ import ( ...@@ -28,8 +28,9 @@ import (
) )
func helperCommand(t *testing.T, s ...string) *exec.Cmd { func helperCommand(t *testing.T, s ...string) *exec.Cmd {
if runtime.GOOS == "nacl" { if runtime.GOOS == "nacl" || (runtime.GOOS == "darwin" && runtime.GOARCH == "arm") {
t.Skip("skipping on nacl") // iOS cannot fork
t.Skipf("skipping on %s/%s", runtime.GOOS, runtime.GOARCH)
} }
cs := []string{"-test.run=TestHelperProcess", "--"} cs := []string{"-test.run=TestHelperProcess", "--"}
cs = append(cs, s...) cs = append(cs, s...)
...@@ -49,6 +50,10 @@ func TestEcho(t *testing.T) { ...@@ -49,6 +50,10 @@ func TestEcho(t *testing.T) {
} }
func TestCommandRelativeName(t *testing.T) { func TestCommandRelativeName(t *testing.T) {
if runtime.GOOS == "darwin" && runtime.GOARCH == "arm" {
t.Skip("skipping on darwin/arm")
}
// Run our own binary as a relative path // Run our own binary as a relative path
// (e.g. "_test/exec.test") our parent directory. // (e.g. "_test/exec.test") our parent directory.
base := filepath.Base(os.Args[0]) // "exec.test" base := filepath.Base(os.Args[0]) // "exec.test"
...@@ -378,6 +383,10 @@ func TestExtraFiles(t *testing.T) { ...@@ -378,6 +383,10 @@ func TestExtraFiles(t *testing.T) {
switch runtime.GOOS { switch runtime.GOOS {
case "nacl", "windows": case "nacl", "windows":
t.Skipf("skipping test on %q", runtime.GOOS) t.Skipf("skipping test on %q", runtime.GOOS)
case "darwin":
if runtime.GOARCH == "arm" {
t.Skipf("skipping test on %s/%s", runtime.GOOS, runtime.GOARCH)
}
} }
// Ensure that file descriptors have not already been leaked into // Ensure that file descriptors have not already been leaked into
......
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