| 1 | sudo: false |
| 2 | language: go |
| 3 | go: |
| 4 | - 1.7.x |
| 5 | - 1.8.x |
| 6 | - 1.9.x |
| 7 | - 1.10.x |
| 8 | - 1.11.x |
| 9 | - tip |
| 10 | |
| 11 | before_install: |
| 12 | - go install -race std |
| 13 | - go get golang.org/x/tools/cmd/cover |
| 14 | - go get github.com/tebeka/go2xunit |
| 15 | - go get github.com/t-yuki/gocover-cobertura |
| 16 | - go get -v ./... |
| 17 | |
| 18 | script: |
| 19 | - go test -v -race ./... | tee gotest.out |
| 20 | - $GOPATH/bin/go2xunit -fail -input gotest.out -output xunit.xml |
| 21 | - go test -v -coverprofile=coverage.txt -covermode count . |
| 22 | - $GOPATH/bin/gocover-cobertura < coverage.txt > coverage.xml |
| 23 | |
| 24 | after_script: |
| 25 | - npm install -g @zeus-ci/cli |
| 26 | - zeus upload -t "application/x-cobertura+xml" coverage.xml |
| 27 | - zeus upload -t "application/x-xunit+xml" xunit.xml |
| 28 | |
| 29 | matrix: |
| 30 | allow_failures: |
| 31 | - go: tip |
| 32 | |
| 33 | notifications: |
| 34 | webhooks: |
| 35 | urls: |
| 36 | - https://zeus.ci/hooks/cd949996-d30a-11e8-ba53-0a580a28042d/public/provider/travis/webhook |
| 37 | on_success: always |
| 38 | on_failure: always |
| 39 | on_start: always |
| 40 | on_cancel: always |
| 41 | on_error: always |