forked from phobos/phobos
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
37 lines (31 loc) · 1.11 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
sudo: required
language: ruby
rvm:
- 2.5.1
- 2.4.4
- 2.3.7
services:
- docker
env:
global:
- DEFAULT_TIMEOUT=20
- CC_TEST_REPORTER_ID=a990fd40ff4421e8b28167232242a1d6c6638f9907fc0b80eb90f82f88fcfd81
before_install:
- env
- docker-compose --version
- docker --version
- docker-compose config
- docker-compose up -d --force-recreate kafka zookeeper
- docker-compose build test
before_script:
- curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter
- chmod +x ./cc-test-reporter
- if [ "$TRAVIS_PULL_REQUEST" == "false" ]; then ./cc-test-reporter before-build || echo "Skipping CC coverage before-build"; fi
- mkdir coverage/
- touch ./coverage/.resultset.json
script:
- docker-compose run --rm test
after_script:
- cat ./coverage/.resultset.json | sed "s|/opt/phobos|$PWD|" > ./coverage/.newresultset.json
- cp ./coverage/.newresultset.json ./coverage/.resultset.json
- if [ "$TRAVIS_PULL_REQUEST" == "false" ]; then ./cc-test-reporter after-build --exit-code $TRAVIS_TEST_RESULT || echo "Skipping CC coverage after-build"; fi