Commit 107b8fc9 authored by David Crawshaw's avatar David Crawshaw

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
parent f2b59a34
...@@ -99,6 +99,13 @@ xcd() { ...@@ -99,6 +99,13 @@ xcd() {
# Strictly speaking, the test may be unnecessary on the final command of # 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. # 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 ] || [ "$CGO_ENABLED" != 1 ] ||
[ "$GOHOSTOS" == windows ] || [ "$GOHOSTOS" == windows ] ||
(xcd ../misc/cgo/stdio (xcd ../misc/cgo/stdio
...@@ -128,7 +135,7 @@ darwin-386 | darwin-amd64) ...@@ -128,7 +135,7 @@ darwin-386 | darwin-amd64)
*) go test -ldflags '-linkmode=external' || exit 1;; *) go test -ldflags '-linkmode=external' || exit 1;;
esac 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=external' || exit 1
go test -ldflags '-linkmode=auto' ../testtls || exit 1 go test -ldflags '-linkmode=auto' ../testtls || exit 1
go test -ldflags '-linkmode=external' ../testtls || exit 1 go test -ldflags '-linkmode=external' ../testtls || exit 1
...@@ -182,16 +189,19 @@ go run main.go || exit 1 ...@@ -182,16 +189,19 @@ go run main.go || exit 1
) || exit $? ) || exit $?
[ "$GOOS" == nacl ] || [ "$GOOS" == nacl ] ||
[ "$GOOS" == android ] ||
(xcd ../doc/progs (xcd ../doc/progs
time ./run || exit 1 time ./run || exit 1
) || exit $? ) || exit $?
[ "$GOOS" == android ] ||
[ "$GOOS" == nacl ] || [ "$GOOS" == nacl ] ||
[ "$GOARCH" == arm ] || # uses network, fails under QEMU [ "$GOARCH" == arm ] || # uses network, fails under QEMU
(xcd ../doc/articles/wiki (xcd ../doc/articles/wiki
./test.bash || exit 1 ./test.bash || exit 1
) || exit $? ) || exit $?
[ "$GOOS" == android ] ||
[ "$GOOS" == nacl ] || [ "$GOOS" == nacl ] ||
(xcd ../doc/codewalk (xcd ../doc/codewalk
time ./run || exit 1 time ./run || exit 1
...@@ -203,6 +213,7 @@ time ./run || exit 1 ...@@ -203,6 +213,7 @@ time ./run || exit 1
time ./timing.sh -test || exit 1 time ./timing.sh -test || exit 1
) || exit $? ) || exit $?
[ "$GOOS" == android ] || # TODO(crawshaw): get this working
[ "$GOOS" == openbsd ] || # golang.org/issue/5057 [ "$GOOS" == openbsd ] || # golang.org/issue/5057
( (
echo echo
...@@ -210,6 +221,7 @@ echo '#' ../test/bench/go1 ...@@ -210,6 +221,7 @@ echo '#' ../test/bench/go1
go test ../test/bench/go1 || exit 1 go test ../test/bench/go1 || exit 1
) || exit $? ) || exit $?
[ "$GOOS" == android ] ||
(xcd ../test (xcd ../test
unset GOMAXPROCS unset GOMAXPROCS
GOOS=$GOHOSTOS GOARCH=$GOHOSTARCH go build -o runtest run.go || exit 1 GOOS=$GOHOSTOS GOARCH=$GOHOSTARCH go build -o runtest run.go || exit 1
...@@ -217,6 +229,7 @@ time ./runtest || exit 1 ...@@ -217,6 +229,7 @@ time ./runtest || exit 1
rm -f runtest rm -f runtest
) || exit $? ) || exit $?
[ "$GOOS" == android ] ||
[ "$GOOS" == nacl ] || [ "$GOOS" == nacl ] ||
( (
echo echo
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment