From b1447f3f25a3405aa58924a86c55ac70ec08e4f0 Mon Sep 17 00:00:00 2001 From: Tobias Klauser Date: Fri, 1 Oct 2021 15:02:38 +0200 Subject: [PATCH] unix: enable TestPassFD and TestPoll on darwin/arm64 Go 1.16 renamed the iOS port from darwin/arm64 to ios/arm64 and darwin/arm64 was repurposed for the macOS ARM64 port (see https://golang.org/doc/go1.16#darwin). Now that Go 1.16 is the oldest supported release, the ios tag can be used exclusively to detect iOS. Thus, TestPassFD and TestPoll which ought to run on darwin/arm64 can now be enabled on that platform. For golang/go#45696 Change-Id: I0b542af7a1b5ab194bf249d499c49e45bb55a2e1 Reviewed-on: https://go-review.googlesource.com/c/sys/+/353529 Trust: Tobias Klauser Run-TryBot: Tobias Klauser TryBot-Result: Go Bot Reviewed-by: Ian Lance Taylor --- unix/syscall_unix_test.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/unix/syscall_unix_test.go b/unix/syscall_unix_test.go index 2f672832..4d66d1d8 100644 --- a/unix/syscall_unix_test.go +++ b/unix/syscall_unix_test.go @@ -167,7 +167,7 @@ func TestFcntlFlock(t *testing.T) { // "-test.run=^TestPassFD$" and an environment variable used to signal // that the test should become the child process instead. func TestPassFD(t *testing.T) { - if (runtime.GOOS == "darwin" || runtime.GOOS == "ios") && runtime.GOARCH == "arm64" { + if runtime.GOOS == "ios" { t.Skip("cannot exec subprocess on iOS, skipping test") } @@ -488,8 +488,7 @@ func TestDup(t *testing.T) { } func TestPoll(t *testing.T) { - if runtime.GOOS == "android" || - ((runtime.GOOS == "darwin" || runtime.GOOS == "ios") && runtime.GOARCH == "arm64") { + if runtime.GOOS == "android" || runtime.GOOS == "ios" { t.Skip("mkfifo syscall is not available on android and iOS, skipping test") }