aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/syscall_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'src/runtime/syscall_test.go')
-rw-r--r--src/runtime/syscall_test.go28
1 files changed, 28 insertions, 0 deletions
diff --git a/src/runtime/syscall_test.go b/src/runtime/syscall_test.go
new file mode 100644
index 0000000000..18f3e8e315
--- /dev/null
+++ b/src/runtime/syscall_test.go
@@ -0,0 +1,28 @@
+// Copyright 2025 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package runtime_test
+
+import (
+ "internal/testenv"
+ "runtime"
+ "testing"
+)
+
+func TestSyscallArgs(t *testing.T) {
+ if runtime.GOOS != "darwin" {
+ t.Skipf("skipping test: GOARCH=%s", runtime.GOARCH)
+ }
+ testenv.MustHaveCGO(t)
+
+ exe, err := buildTestProg(t, "testsyscall")
+ if err != nil {
+ t.Fatal(err)
+ }
+
+ cmd := testenv.Command(t, exe)
+ if out, err := cmd.CombinedOutput(); err != nil {
+ t.Fatalf("test program failed: %v\n%s", err, out)
+ }
+}