[build] Aggregated coverage report
This commit is contained in:
@@ -1,7 +1,27 @@
|
|||||||
plugins {
|
plugins {
|
||||||
id("java")
|
`jacoco-report-aggregation`
|
||||||
id("maven-publish")
|
`maven-publish`
|
||||||
}
|
}
|
||||||
|
|
||||||
group = "de.siphalor.tweed5"
|
group = "de.siphalor.tweed5"
|
||||||
version = properties["version"]!!
|
version = properties["version"]!!
|
||||||
|
|
||||||
|
repositories {
|
||||||
|
mavenCentral()
|
||||||
|
}
|
||||||
|
|
||||||
|
dependencies {
|
||||||
|
rootProject.subprojects.forEach { subproject ->
|
||||||
|
subproject.plugins.withId("jacoco") {
|
||||||
|
jacocoAggregation(project(subproject.path))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
reporting {
|
||||||
|
reports {
|
||||||
|
val aggregatedCoverageReport by creating(JacocoCoverageReport::class) {
|
||||||
|
testSuiteName = "test"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
plugins {
|
plugins {
|
||||||
java
|
java
|
||||||
`java-library`
|
`java-library`
|
||||||
|
jacoco
|
||||||
`maven-publish`
|
`maven-publish`
|
||||||
alias(libs.plugins.lombok)
|
alias(libs.plugins.lombok)
|
||||||
id("de.siphalor.tweed5.local-runtime-only")
|
id("de.siphalor.tweed5.local-runtime-only")
|
||||||
@@ -61,6 +62,7 @@ tasks.compileTestJava {
|
|||||||
|
|
||||||
tasks.test {
|
tasks.test {
|
||||||
dependsOn(testAgentClasspath)
|
dependsOn(testAgentClasspath)
|
||||||
|
finalizedBy(tasks.jacocoTestReport)
|
||||||
|
|
||||||
useJUnitPlatform()
|
useJUnitPlatform()
|
||||||
jvmArgs(testAgentClasspath.get().files.map { file -> "-javaagent:${file.absolutePath}" })
|
jvmArgs(testAgentClasspath.get().files.map { file -> "-javaagent:${file.absolutePath}" })
|
||||||
@@ -71,6 +73,10 @@ tasks.test {
|
|||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
tasks.jacocoTestReport {
|
||||||
|
dependsOn(tasks.test)
|
||||||
|
}
|
||||||
|
|
||||||
publishing {
|
publishing {
|
||||||
publications {
|
publications {
|
||||||
create<MavenPublication>("lib") {
|
create<MavenPublication>("lib") {
|
||||||
|
|||||||
@@ -1,6 +1,3 @@
|
|||||||
import gradle.kotlin.dsl.accessors._182d53d78a136df48d95cf7411f9259f.lombok
|
|
||||||
import org.gradle.kotlin.dsl.assign
|
|
||||||
|
|
||||||
plugins {
|
plugins {
|
||||||
java
|
java
|
||||||
alias(libs.plugins.lombok)
|
alias(libs.plugins.lombok)
|
||||||
|
|||||||
Reference in New Issue
Block a user