import "C"
import (
+ "runtime"
"sync"
"testing"
)
}
func testCthread(t *testing.T) {
+ if runtime.GOOS == "darwin" && (runtime.GOARCH == "arm" || runtime.GOARCH == "arm64") {
+ t.Skip("the iOS exec wrapper is unable to properly handle the panic from Add")
+ }
sum.i = 0
C.doAdd(10, 6)
if C.HAS_SYNC_FETCH_AND_ADD == 0 {
t.Skip("clang required for __sync_fetch_and_add support on darwin/arm")
}
- if runtime.GOOS == "android" {
+ if runtime.GOOS == "android" || runtime.GOOS == "darwin" && (runtime.GOARCH == "arm" || runtime.GOARCH == "arm64") {
t.Skip("GOTRACEBACK is not passed on to the exec wrapper")
}
if os.Getenv("GOTRACEBACK") != "2" {
})
}
}
- if t.cgoEnabled && !t.iOS() {
- // TODO(crawshaw): reenable on iOS
- // golang.org/issue/15919
- //
- // These tests are not designed to run off the host.
+ if t.cgoEnabled {
t.tests = append(t.tests, distTest{
name: "cgo_test",
heading: "../misc/cgo/test",
func (t *tester) cgoTest(dt *distTest) error {
env := mergeEnvLists([]string{"GOTRACEBACK=2"}, os.Environ())
- if t.iOS() {
- cmd := t.dirCmd("misc/cgo/test", "go", "test", t.tags())
- cmd.Env = env
- return cmd.Run()
- }
-
cmd := t.addCmd(dt, "misc/cgo/test", "go", "test", t.tags(), "-ldflags", "-linkmode=auto", t.runFlag(""))
cmd.Env = env