Skip to content

Commit 9f4ccab

Browse files
author
Daniel Rees
committed
Adding Jacoco test coverage
1 parent 760a81b commit 9f4ccab

File tree

4 files changed

+22
-2
lines changed

4 files changed

+22
-2
lines changed

.travis.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
language: java
2+
after_success:
3+
- bash <(curl -s https://codecov.io/bash)
24
jdk:
35
- oraclejdk8
46
sudo: false

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
# JavaPhoenixClient
22

3-
[ ![Download](https://api.bintray.com/packages/drees/java-phoenix-client/JavaPhoenixClient/images/download.svg) ](https://bintray.com/drees/java-phoenix-client/JavaPhoenixClient/_latestVersion)
3+
[![Download](https://api.bintray.com/packages/drees/java-phoenix-client/JavaPhoenixClient/images/download.svg) ](https://bintray.com/drees/java-phoenix-client/JavaPhoenixClient/_latestVersion)
44
[![Build Status](https://travis-ci.com/dsrees/JavaPhoenixClient.svg?branch=master)](https://travis-ci.com/dsrees/JavaPhoenixClient)
5+
[![codecov](https://codecov.io/gh/dsrees/JavaPhoenixClient/branch/master/graph/badge.svg)](https://codecov.io/gh/dsrees/JavaPhoenixClient)
56

67

78
JavaPhoenixClient is a Kotlin implementation of the [phoenix.js](https://hexdocs.pm/phoenix/js/) client used to manage Phoenix channels.

build.gradle

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,15 @@ repositories {
1818
}
1919

2020
test {
21+
// JUnit 5 Support
2122
useJUnitPlatform()
23+
24+
// This allows us see tests execution progress in the output on the CI.
25+
testLogging {
26+
events 'passed', 'skipped', 'failed', 'standardOut', 'standardError'
27+
exceptionFormat 'full'
28+
}
29+
2230
}
2331

2432
dependencies {
@@ -34,6 +42,15 @@ dependencies {
3442
testCompile group: 'com.nhaarman.mockitokotlin2', name: 'mockito-kotlin', version: '2.1.0'
3543
}
3644

45+
jacocoTestReport {
46+
reports {
47+
xml.enabled true
48+
html.enabled false
49+
}
50+
}
51+
52+
53+
3754
compileKotlin {
3855
kotlinOptions.jvmTarget = "1.8"
3956
}

script/deploy.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,5 @@ if [ "$TRAVIS_PULL_REQUEST" == "false" ] && [ "$TRAVIS_TAG" != "" ]; then
55
./gradlew bintrayUpload --stacktrace
66
else
77
echo -e '#### Build for Test => Branch ['$TRAVIS_BRANCH'] Pull Request ['$TRAVIS_PULL_REQUEST'] ####'
8-
./gradlew build
8+
./gradlew clean build jacocoTestReport
99
fi

0 commit comments

Comments
 (0)