gradle-coveralls-plugin
Gradle plugin to upload coverage to Coveralls
Usage
-
Make plugin available to Gradle build script
buildscript { repositories { mavenCentral() } dependencies { classpath 'me.kolek.gradle:gradle-coveralls-plugin:1.0.0' } }
-
Apply plugin to Gradle project
apply plugin: 'me.kolek.coveralls'
-
Configure Coveralls plugin extension
coveralls { // use repo token from COVERALLS_REPO_TOKEN environment variable repoToken System.env.COVERALLS_REPO_TOKEN // upload JaCoCo coverage data jacoco() services { // use Codeship build environment values codeship() // use Travis CI build environment values travis() // use custom/local build environment values custom { // ... } } }
-
Run tests, generate and upload code coverage
gradle test jacocoTestReport uploadCodeCoverage