travis: enable IPv6 before running tests
This commit is contained in:
parent
1a65f972c6
commit
844f528ed8
@ -19,10 +19,11 @@ script:
|
||||
- "gosrc=$(find . -name '*.go' | tr '\\n' ' '); [ $(gofmt -l $gosrc 2>&- | wc -l) -eq 0 ] || (echo 'gofmt was not run on these files:'; gofmt -l $gosrc 2>&-; false)"
|
||||
# TODO: remove the || true suffix once vet errors are fixed
|
||||
- go tool vet . || true
|
||||
- sudo sysctl -w net.ipv6.conf.all.disable_ipv6=0
|
||||
- sudo ip -6 address replace ::1/128 dev lo
|
||||
- go build ./cmd/...
|
||||
- go test -v -race ./internal/...
|
||||
- docker build --pull --no-cache --rm -t=router7 -f travis/Dockerfile .
|
||||
- sudo sysctl -w net.ipv6.conf.all.disable_ipv6=0
|
||||
- sudo service docker restart
|
||||
# NOTE: this must be the last command because of the travis_terminate usage:
|
||||
- exit=0; for pkg in $(go list ./integration/...); do go test -c $pkg && docker run --privileged --net=host -v $PWD:/usr/src:ro router7 /bin/sh -c "./$(basename $pkg).test -test.v" || exit=1; done; [ $exit = 0 ] || travis_terminate 1
|
||||
|
Loading…
x
Reference in New Issue
Block a user