language: go
go:
  - '1.7.x'
  - '1.8.x'
  - '1.9.x'
  - '1.10.x'
  - '1.11.x'
  - '1.12.x'
  - master

sudo: false

before_install:
  - go get -t -v ./...

install:
  - go get
  - go build

script:
  - make test
  - go test -race -coverprofile=coverage.txt -covermode=atomic

after_success:
  - bash <(curl -s https://codecov.io/bash)

matrix:
  allow_failures:
    - go: master
