-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy path.travis.yml
39 lines (39 loc) · 1.02 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
38
39
os:
- linux
dist: trusty
services: postgresql
addons:
postgresql: "10"
language: java
install: true
jdk:
- oraclejdk8
sudo: false
branches:
only:
- master
cache:
directories:
- $HOME/.m2
env:
global:
- GIT_COMMITTED_AT=$(if [ "$TRAVIS_PULL_REQUEST" == "false" ]; then git log -1 --pretty=format:%ct; else git log -1 --skip 1 --pretty=format:%ct; fi)
before_install:
- java -version
script:
- curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter
- chmod +x ./cc-test-reporter
- chmod +x ./mvnw
- ./cc-test-reporter before-build
- ./mvnw clean verify
- TEST_RESULT=$TRAVIS_TEST_RESULT
- JACOCO_SOURCE_PATH=src/main/java ./cc-test-reporter format-coverage target/site/jacoco/jacoco.xml --input-type jacoco
- ./cc-test-reporter upload-coverage
- (exit $TEST_RESULT)
after_success:
- ./mvnw -Dmaven.test.skip=true com.heroku.sdk:heroku-maven-plugin:deploy
notifications:
webhooks:
on_success: change
on_failure: always
on_start: false