.travis.yml 3.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. dist: trusty
  2. language: go
  3. sudo: required
  4. go:
  5. - 1.14.6
  6. addons:
  7. apt_packages:
  8. - libx11-dev
  9. - libgles2-mesa-dev
  10. script:
  11. - cd psiphon
  12. - go test -race -v ./common
  13. - go test -race -v ./common/accesscontrol
  14. - go test -race -v ./common/crypto/ssh
  15. - go test -race -v ./common/fragmentor
  16. - go test -race -v ./common/obfuscator
  17. - go test -race -v ./common/osl
  18. # TODO: enable all packetman tests with tag PACKET_MANIPULATOR_TEST; requires CAP_NETADMIN and CAP_RAW
  19. - go test -race -v ./common/packetman
  20. - go test -race -v ./common/parameters
  21. - go test -race -v ./common/protocol
  22. - go test -race -v ./common/quic
  23. - go test -race -v ./common/tactics
  24. # TODO: fix and reenable test, which is failing in TravisCI environment:
  25. # --- FAIL: TestTunneledTCPIPv4
  26. # tun_test.go:226: startTestTCPClient failed: syscall.Connect failed: connection timed out
  27. #
  28. #- sudo -E env "PATH=$PATH" go test -race -v ./common/tun
  29. - go test -race -v ./common/values
  30. - go test -race -v ./common/wildcard
  31. - go test -race -v ./transferstats
  32. # TODO: seet "packetman" comment above
  33. - go test -race -v ./server
  34. - go test -race -v ./server/psinet
  35. - go test -race -v ../Server/logging/analysis
  36. - go test -race -v ../ClientLibrary/clientlib
  37. - go test -race -v
  38. - go test -v -covermode=count -coverprofile=common.coverprofile ./common
  39. - go test -v -covermode=count -coverprofile=accesscontrol.coverprofile ./common/accesscontrol
  40. - go test -v -covermode=count -coverprofile=ssh.coverprofile ./common/crypto/ssh
  41. - go test -v -covermode=count -coverprofile=fragmentor.coverprofile ./common/fragmentor
  42. - go test -v -covermode=count -coverprofile=obfuscator.coverprofile ./common/obfuscator
  43. - go test -v -covermode=count -coverprofile=osl.coverprofile ./common/osl
  44. - go test -v -covermode=count -coverprofile=parameters.coverprofile ./common/parameters
  45. - go test -v -covermode=count -coverprofile=packetman.coverprofile ./common/packetman
  46. - go test -v -covermode=count -coverprofile=protocol.coverprofile ./common/protocol
  47. - go test -v -covermode=count -coverprofile=quic.coverprofile ./common/quic
  48. - go test -v -covermode=count -coverprofile=tactics.coverprofile ./common/tactics
  49. # TODO: see "tun" test comment above
  50. #- sudo -E env "PATH=$PATH" go test -v -covermode=count -coverprofile=tun.coverprofile ./common/tun
  51. - go test -v -covermode=count -coverprofile=values.coverprofile ./common/values
  52. - go test -v -covermode=count -coverprofile=wildcard.coverprofile ./common/wildcard
  53. - go test -v -covermode=count -coverprofile=transferstats.coverprofile ./transferstats
  54. - go test -v -covermode=count -coverprofile=server.coverprofile ./server
  55. - go test -v -covermode=count -coverprofile=psinet.coverprofile ./server/psinet
  56. - go test -v -covermode=count -coverprofile=analysis.coverprofile ../Server/logging/analysis
  57. - go test -v -covermode=count -coverprofile=clientlib.coverprofile ../ClientLibrary/clientlib
  58. - go test -v -covermode=count -coverprofile=psiphon.coverprofile
  59. - go test -v ./memory_test -run TestReconnectTunnel
  60. - go test -v ./memory_test -run TestRestartController
  61. after_script:
  62. - $HOME/gopath/bin/gover
  63. - $HOME/gopath/bin/goveralls -coverprofile=gover.coverprofile -service=travis-ci -repotoken $COVERALLS_TOKEN
  64. before_install:
  65. - go get github.com/axw/gocov/gocov
  66. - go get github.com/modocache/gover
  67. - go get github.com/mattn/goveralls
  68. - if ! go get github.com/golang/tools/cmd/cover; then go get golang.org/x/tools/cmd/cover; fi
  69. - git rev-parse --short HEAD > psiphon/git_rev
  70. - openssl aes-256-cbc -K $encrypted_bf83b4ab4874_key -iv $encrypted_bf83b4ab4874_iv
  71. -in psiphon/controller_test.config.enc -out psiphon/controller_test.config -d
  72. - openssl aes-256-cbc -K $encrypted_560fd0d04977_key -iv $encrypted_560fd0d04977_iv
  73. -in feedback_test.config.enc -out feedback_test.config -d
  74. notifications:
  75. slack:
  76. rooms:
  77. secure: jVo/BZ1iFtg4g5V+eNxETwXPnbhwVwGzN1vkHJnCLAhV/md3/uHGsZQIMfitqgrX/T+9JBVRbRezjBwfJHYLs40IJTCWt167Lz8R1NlazLyEpcGcdesG05cTl9oEcBb7X52kZt7r8ZIBwdB7W6U/E0/i41qKamiEJqISMsdOoFA=
  78. on_success: always
  79. on_failure: always