From: David Crawshaw Date: Tue, 8 Jul 2014 22:41:07 +0000 (-0400) Subject: run.bash: disable tests that don't (yet) like running off the host X-Git-Tag: go1.4beta1~1144 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=107b8fc9e41cbe365d574f56518ca27e7d9a919d;p=gostls13.git run.bash: disable tests that don't (yet) like running off the host LGTM=bradfitz, minux R=bradfitz, golang-codereviews, minux CC=golang-codereviews https://golang.org/cl/110940043 --- diff --git a/src/run.bash b/src/run.bash index 128f15c395..d13161e9de 100755 --- a/src/run.bash +++ b/src/run.bash @@ -99,6 +99,13 @@ xcd() { # Strictly speaking, the test may be unnecessary on the final command of # the subshell, but it aids later editing and may avoid future bash bugs. +if [ "$GOOS" == "android" ]; then + # Disable cgo tests on android. + # They are not designed to run off the host. + # golang.org/issue/8345 + CGO_ENABLED=0 +fi + [ "$CGO_ENABLED" != 1 ] || [ "$GOHOSTOS" == windows ] || (xcd ../misc/cgo/stdio @@ -128,7 +135,7 @@ darwin-386 | darwin-amd64) *) go test -ldflags '-linkmode=external' || exit 1;; esac ;; -dragonfly-386 | dragonfly-amd64 | freebsd-386 | freebsd-amd64 | freebsd-arm | linux-386 | linux-amd64 | linux-arm | netbsd-386 | netbsd-amd64) +android-arm | dragonfly-386 | dragonfly-amd64 | freebsd-386 | freebsd-amd64 | freebsd-arm | linux-386 | linux-amd64 | linux-arm | netbsd-386 | netbsd-amd64) go test -ldflags '-linkmode=external' || exit 1 go test -ldflags '-linkmode=auto' ../testtls || exit 1 go test -ldflags '-linkmode=external' ../testtls || exit 1 @@ -182,16 +189,19 @@ go run main.go || exit 1 ) || exit $? [ "$GOOS" == nacl ] || +[ "$GOOS" == android ] || (xcd ../doc/progs time ./run || exit 1 ) || exit $? +[ "$GOOS" == android ] || [ "$GOOS" == nacl ] || [ "$GOARCH" == arm ] || # uses network, fails under QEMU (xcd ../doc/articles/wiki ./test.bash || exit 1 ) || exit $? +[ "$GOOS" == android ] || [ "$GOOS" == nacl ] || (xcd ../doc/codewalk time ./run || exit 1 @@ -203,6 +213,7 @@ time ./run || exit 1 time ./timing.sh -test || exit 1 ) || exit $? +[ "$GOOS" == android ] || # TODO(crawshaw): get this working [ "$GOOS" == openbsd ] || # golang.org/issue/5057 ( echo @@ -210,6 +221,7 @@ echo '#' ../test/bench/go1 go test ../test/bench/go1 || exit 1 ) || exit $? +[ "$GOOS" == android ] || (xcd ../test unset GOMAXPROCS GOOS=$GOHOSTOS GOARCH=$GOHOSTARCH go build -o runtest run.go || exit 1 @@ -217,6 +229,7 @@ time ./runtest || exit 1 rm -f runtest ) || exit $? +[ "$GOOS" == android ] || [ "$GOOS" == nacl ] || ( echo