| # Copyright 2014 Marc-Antoine Ruel. All rights reserved. |
| # Use of this source code is governed under the Apache License, Version 2.0 |
| # that can be found in the LICENSE file. |
| |
| sudo: false |
| language: go |
| |
| go: |
| - 1.9.7 |
| - 1.x |
| |
| before_script: |
| - go get -u -v github.com/client9/misspell/cmd/misspell github.com/gordonklaus/ineffassign golang.org/x/tools/go/analysis/passes/shadow/cmd/shadow |
| |
| script: |
| - echo 'Check Code is well formatted'; ! gofmt -s -d . | read |
| - echo 'Erroring on misspelling'; ! misspell . | grep a |
| - ineffassign . |
| - if [[ $TRAVIS_GO_VERSION != 1.9.7 ]]; then go vet -vettool=$GOPATH/bin/shadow ./...; fi |
| - go test -cover ./... |
| - go test -race ./... |