Skip to content

Commit

Permalink
Fix CI on Go 1.12
Browse files Browse the repository at this point in the history
  • Loading branch information
at-wat committed May 8, 2020
1 parent 980ebb7 commit 5252183
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,12 @@ language: go
go:
- "1.12"
- "1.13"
- "1.14"
- master

env:
global:
- REVIEW_DOG_ON=1.13
- REVIEW_DOG_ON=1.14
- REVIEW_DOG_VERSION=0.9.17
- GO111MODULE=on

Expand All @@ -24,11 +25,17 @@ install:
| tar xzfv - -C ${GOPATH}/bin
fi
script:
- go build
- go build ./...
- |
echo "Enable coverage report"
TEST_ARG="-coverprofile=coverage.txt -covermode=atomic -coverpkg=all"
- go test -v ${TEST_ARG} $(go list ./... | grep -v "/examples/")
- TEST_PKGS="$(go list ./... | grep -v "/examples/")"
- |
if [ ${TRAVIS_GO_VERSION} == "1.12" ]; then
# Skip testing cmd to workaround https://github.com/golang/go/issues/30374
TEST_PKGS="$(go list ./... | grep -v "/examples/" | grep -v "/cmd/")"
fi
- go test -v ${TEST_ARG} ${TEST_PKGS}
- go vet ./...
- |
if [ ${TRAVIS_GO_VERSION} == ${REVIEW_DOG_ON} ]; then
Expand Down

0 comments on commit 5252183

Please sign in to comment.