From: Elias Naur Date: Sat, 7 Sep 2019 22:21:57 +0000 (+0200) Subject: net,os: disable more sysctl tests on iOS X-Git-Tag: go1.14beta1~1169 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=2711fababd21c471dc0c64b33972c74a7c4eee20;p=gostls13.git net,os: disable more sysctl tests on iOS Updates #34133 Change-Id: I27c75993176cf876f2d80f70982528258c509b68 Reviewed-on: https://go-review.googlesource.com/c/go/+/193845 Run-TryBot: Elias Naur Reviewed-by: Emmanuel Odeke --- diff --git a/src/net/interface_test.go b/src/net/interface_test.go index fb6032fbc0..6cdfb6265f 100644 --- a/src/net/interface_test.go +++ b/src/net/interface_test.go @@ -51,6 +51,9 @@ func ipv6LinkLocalUnicastAddr(ifi *Interface) string { } func TestInterfaces(t *testing.T) { + if runtime.GOOS == "darwin" && (runtime.GOARCH == "arm" || runtime.GOARCH == "arm64") { + t.Skipf("sysctl is not supported on iOS") + } ift, err := Interfaces() if err != nil { t.Fatal(err) @@ -82,6 +85,9 @@ func TestInterfaces(t *testing.T) { } func TestInterfaceAddrs(t *testing.T) { + if runtime.GOOS == "darwin" && (runtime.GOARCH == "arm" || runtime.GOARCH == "arm64") { + t.Skipf("sysctl is not supported on iOS") + } ift, err := Interfaces() if err != nil { t.Fatal(err) @@ -101,6 +107,9 @@ func TestInterfaceAddrs(t *testing.T) { } func TestInterfaceUnicastAddrs(t *testing.T) { + if runtime.GOOS == "darwin" && (runtime.GOARCH == "arm" || runtime.GOARCH == "arm64") { + t.Skipf("sysctl is not supported on iOS") + } ift, err := Interfaces() if err != nil { t.Fatal(err) @@ -128,6 +137,9 @@ func TestInterfaceUnicastAddrs(t *testing.T) { } func TestInterfaceMulticastAddrs(t *testing.T) { + if runtime.GOOS == "darwin" && (runtime.GOARCH == "arm" || runtime.GOARCH == "arm64") { + t.Skipf("sysctl is not supported on iOS") + } ift, err := Interfaces() if err != nil { t.Fatal(err) diff --git a/src/os/os_test.go b/src/os/os_test.go index 6c88d7e8b8..974374ec66 100644 --- a/src/os/os_test.go +++ b/src/os/os_test.go @@ -1521,6 +1521,9 @@ func testWindowsHostname(t *testing.T, hostname string) { } func TestHostname(t *testing.T) { + if runtime.GOOS == "darwin" && (runtime.GOARCH == "arm" || runtime.GOARCH == "arm64") { + t.Skipf("sysctl is not supported on iOS") + } hostname, err := Hostname() if err != nil { t.Fatal(err)