mirror of
https://github.com/pgpainless/pgpainless.git
synced 2024-11-17 18:02:05 +01:00
Add jacoco
This commit is contained in:
parent
528048e4df
commit
9b68ee67d9
1 changed files with 28 additions and 0 deletions
28
build.gradle
28
build.gradle
|
@ -22,6 +22,7 @@ allprojects {
|
|||
apply plugin: 'java'
|
||||
apply plugin: 'idea'
|
||||
apply plugin: 'eclipse'
|
||||
apply plugin: 'jacoco'
|
||||
apply plugin: 'checkstyle'
|
||||
|
||||
// animalsniffer
|
||||
|
@ -75,6 +76,19 @@ allprojects {
|
|||
'git tag --points-at HEAD'.execute().text.trim())
|
||||
}
|
||||
|
||||
jacoco {
|
||||
toolVersion = "0.8.1"
|
||||
}
|
||||
|
||||
jacocoTestReport {
|
||||
dependsOn test
|
||||
sourceDirectories = project.files(sourceSets.main.allSource.srcDirs)
|
||||
classDirectories = project.files(sourceSets.main.output)
|
||||
reports {
|
||||
xml.enabled true
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
subprojects {
|
||||
|
@ -199,6 +213,20 @@ def getGitCommit() {
|
|||
gitCommit
|
||||
}
|
||||
|
||||
/*
|
||||
task jacocoRootReport(type: JacocoReport) {
|
||||
reports {
|
||||
xml.enabled true
|
||||
xml.destination file("${buildDir}/reports/jacoco/test/jacocoTestReport.xml")
|
||||
}
|
||||
// We could remove the following setOnlyIf line, but then
|
||||
// jacocoRootReport would silently be SKIPPED if something with
|
||||
// the projectsWithUnitTests is wrong (e.g. a project is missing
|
||||
// in there).
|
||||
setOnlyIf { true }
|
||||
}
|
||||
*/
|
||||
|
||||
task javadocAll(type: Javadoc) {
|
||||
source subprojects.collect {project ->
|
||||
project.sourceSets.main.allJava }
|
||||
|
|
Loading…
Reference in a new issue