language: go
go:
  - "1.8.x"
  - "1.9.x"
  - "1.10.x"
  - "1.11.x"
  - "stable"
  - tip

env:
  - GO111MODULE: "on"

matrix:
  allow_failures:
    - go: tip

script:
  - if [ "${TRAVIS_GO_VERSION}" = "stable" ]; then make check-mod; fi
  - if [ "${TRAVIS_GO_VERSION}" = "stable" ]; then make golangci-lint; fi
  - if [ "${TRAVIS_GO_VERSION}" = "stable" ]; then echo running check scripts; make check; fi
  - make build
  - make TEST_FLAGS="-v" test
