]> Cypherpunks repositories - gostls13.git/commitdiff
net: skip unsupported tests (unix and unixgram) on darwin/arm
authorShenghou Ma <minux@golang.org>
Thu, 26 Feb 2015 23:25:29 +0000 (18:25 -0500)
committerMinux Ma <minux@golang.org>
Wed, 4 Mar 2015 22:12:05 +0000 (22:12 +0000)
Change-Id: Id1927180ecd18b849727225adea05465d36b3973
Reviewed-on: https://go-review.googlesource.com/6210
Reviewed-by: Mikio Hara <mikioh.mikioh@gmail.com>
Reviewed-by: David Crawshaw <crawshaw@golang.org>
src/net/conn_test.go
src/net/net_test.go
src/net/packetconn_test.go
src/net/protoconn_test.go
src/net/server_test.go

index 9c9d1a8057de8bb1756f4e1c6a822db432ed7726..b86ef437fb4888723ef0ed6fd98406bd766070e1 100644 (file)
@@ -36,6 +36,10 @@ func TestConnAndListener(t *testing.T) {
                        case "nacl", "plan9", "windows":
                                continue
                        }
+                       // iOS does not support unix domain sockets
+                       if runtime.GOOS == "darwin" && runtime.GOARCH == "arm" {
+                               continue
+                       }
                case "unixpacket":
                        switch runtime.GOOS {
                        case "android", "darwin", "nacl", "openbsd", "plan9", "windows":
index bfed4d657fdde064f741076c88f001d948620068..acf9ee5a35afabcac3b3ef9a7865433d43a3bdf2 100644 (file)
@@ -66,6 +66,10 @@ func TestShutdownUnix(t *testing.T) {
        switch runtime.GOOS {
        case "nacl", "plan9", "windows":
                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)
+               }
        }
        f, err := ioutil.TempFile("", "go_net_unixtest")
        if err != nil {
index 5bbfc0f82ae5999bb9aee30407c52937e6bc598c..72bdb49196c23f3b42377ad9b62bb0e32ceb4e4b 100644 (file)
@@ -51,6 +51,9 @@ var packetConnTests = []struct {
 }
 
 func TestPacketConn(t *testing.T) {
+       if runtime.GOOS == "darwin" && runtime.GOARCH == "arm" {
+               t.Skip("skipping test on darwin/arm")
+       }
        closer := func(c PacketConn, net, addr1, addr2 string) {
                c.Close()
                switch net {
@@ -106,6 +109,9 @@ func TestPacketConn(t *testing.T) {
 }
 
 func TestConnAndPacketConn(t *testing.T) {
+       if runtime.GOOS == "darwin" && runtime.GOARCH == "arm" {
+               t.Skip("skipping test on darwin/arm")
+       }
        closer := func(c PacketConn, net, addr1, addr2 string) {
                c.Close()
                switch net {
index 61c35dfc703b44c4eaf379065476d868ccd690dc..18ac4a6bdf1354e16dcbf1ce4a05c7a0444e13b9 100644 (file)
@@ -221,6 +221,10 @@ func TestUnixListenerSpecificMethods(t *testing.T) {
        switch runtime.GOOS {
        case "nacl", "plan9", "windows":
                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)
+               }
        }
 
        addr := testUnixAddr()
@@ -263,6 +267,10 @@ func TestUnixConnSpecificMethods(t *testing.T) {
        switch runtime.GOOS {
        case "nacl", "plan9", "windows":
                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)
+               }
        }
 
        addr1, addr2, addr3 := testUnixAddr(), testUnixAddr(), testUnixAddr()
index bf7feab8f515aaab336267d6de31efcc23974b8a..e0768e67cf7e56ae616899da4d0463c012d7a71f 100644 (file)
@@ -21,6 +21,10 @@ func skipServerTest(net, unixsotype, addr string, ipv6, ipv4map, linuxOnly bool)
                if net == unixsotype {
                        return true
                }
+       case "darwin":
+               if runtime.GOARCH == "arm" && net == unixsotype {
+                       return true
+               }
        default:
                if net == unixsotype && linuxOnly {
                        return true