mirror of
https://github.com/RipMeApp/ripme.git
synced 2025-08-11 08:24:10 +02:00
gradle, produce jacoco coverage report, html
This commit is contained in:
@@ -1,4 +1,5 @@
|
|||||||
plugins {
|
plugins {
|
||||||
|
id("jacoco")
|
||||||
id("java")
|
id("java")
|
||||||
id("maven-publish")
|
id("maven-publish")
|
||||||
}
|
}
|
||||||
@@ -64,6 +65,7 @@ tasks.test {
|
|||||||
includeEngines("junit-jupiter")
|
includeEngines("junit-jupiter")
|
||||||
includeEngines("junit-vintage")
|
includeEngines("junit-vintage")
|
||||||
}
|
}
|
||||||
|
finalizedBy(tasks.jacocoTestReport) // report is always generated after tests run
|
||||||
}
|
}
|
||||||
|
|
||||||
// make all archive tasks in the build reproducible
|
// make all archive tasks in the build reproducible
|
||||||
@@ -72,3 +74,12 @@ tasks.withType<AbstractArchiveTask>().configureEach {
|
|||||||
isReproducibleFileOrder = true
|
isReproducibleFileOrder = true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
tasks.jacocoTestReport {
|
||||||
|
dependsOn(tasks.test) // tests are required to run before generating the report
|
||||||
|
reports {
|
||||||
|
xml.isEnabled = false
|
||||||
|
csv.isEnabled = false
|
||||||
|
html.destination = file("${buildDir}/jacocoHtml")
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user