-
-
Notifications
You must be signed in to change notification settings - Fork 233
/
.travis.yml
43 lines (34 loc) · 1.46 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
40
41
42
43
# Travis CI Java documentation can be found in:
# https://docs.travis-ci.com/user/languages/java/
# We will use Ubuntu 18.04 (bionic beaver). List of options:
# https://docs.travis-ci.com/user/reference/overview/#linux
dist: xenial
services:
# Linking Travis CI and Docker
- docker
# This enables the 'defaults' to test java applications:
language: java
# We can specify a list of JDKs to be used for testing
# A list of available JDKs in Trusty can be seed in:
# https://docs.travis-ci.com/user/reference/xenial/#jvm-clojure-groovy-java-scala-support
jdk:
- openjdk8
before_install:
- mvn clean
- echo "$DOCKER_PASS" | docker login -u "$DOCKER_USER" --password-stdin
- docker pull openjdk:8-jdk-alpine
# git strips the wrapper jar file so we have to force its download during the build
install:
- mvn -N io.takari:maven:wrapper
- ./mvnw install -DskipTests=true -Dmaven.javadoc.skip=true -B -V
# Each job in Travis CI has several steps:
# https://docs.travis-ci.com/user/job-lifecycle/
# The 'language: java' directive sets up sane defaults to test common java applications
# We use the defaults for installing dependencies, compiling and testing maven applications
# In our case it will be 'mvn install' followed by 'mvn test'
# https://github.com/codecov/example-java-maven
script: "mvn cobertura:cobertura"
# This is to enable CodeCov's coverage
# If a build is successful, the code is submitted for coverage analysis
after_success:
- bash <(curl -s https://codecov.io/bash)