.travis.yml 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. language: go
  2. sudo: false
  3. matrix:
  4. fast_finish: true
  5. allow_failures:
  6. - go: tip
  7. go:
  8. - '1.11.x'
  9. - '1.12.x'
  10. - tip
  11. go_import_path: gopkg.in/square/go-jose.v2
  12. before_script:
  13. - export PATH=$HOME/.local/bin:$PATH
  14. before_install:
  15. # Install encrypted gitcookies to get around bandwidth-limits
  16. # that is causing Travis-CI builds to fail. For more info, see
  17. # https://github.com/golang/go/issues/12933
  18. - openssl aes-256-cbc -K $encrypted_1528c3c2cafd_key -iv $encrypted_1528c3c2cafd_iv -in .gitcookies.sh.enc -out .gitcookies.sh -d || true
  19. - bash .gitcookies.sh || true
  20. - go get github.com/wadey/gocovmerge
  21. - go get github.com/mattn/goveralls
  22. - go get github.com/stretchr/testify/assert
  23. - go get golang.org/x/tools/cmd/cover || true
  24. - go get code.google.com/p/go.tools/cmd/cover || true
  25. - pip install cram --user
  26. script:
  27. - go test . -v -covermode=count -coverprofile=profile.cov
  28. - go test ./cipher -v -covermode=count -coverprofile=cipher/profile.cov
  29. - go test ./jwt -v -covermode=count -coverprofile=jwt/profile.cov
  30. - go test ./json -v # no coverage for forked encoding/json package
  31. - cd jose-util && go build && PATH=$PWD:$PATH cram -v jose-util.t
  32. - cd ..
  33. after_success:
  34. - gocovmerge *.cov */*.cov > merged.coverprofile
  35. - $HOME/gopath/bin/goveralls -coverprofile merged.coverprofile -service=travis-ci