Skip to content

Commit 2d157f1

Browse files
committed
Migrate gradle configuration to kotlin
1 parent 3a1d102 commit 2d157f1

1 file changed

Lines changed: 2 additions & 13 deletions

File tree

build.gradle.kts

Lines changed: 2 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ plugins {
55
id("org.springframework.boot") version "3.4.5" apply false
66
id("io.spring.dependency-management") version "1.1.7"
77
id("org.sonarqube") version "6.2.0.5505"
8-
jacoco
8+
id("jacoco-report-aggregation")
99
}
1010

1111
group = "zin.rashidi.boot"
@@ -31,14 +31,6 @@ dependencies {
3131
implementation(platform(SpringBootPlugin.BOM_COORDINATES))
3232
}
3333

34-
// Simple JaCoCo report task
35-
val reportTask = tasks.register<JacocoReport>("testCodeCoverageReport") {
36-
reports {
37-
xml.required.set(true)
38-
html.required.set(true)
39-
}
40-
}
41-
4234
sonar {
4335
properties {
4436
property("sonar.projectKey", "rashidi_spring-boot-tutorials")
@@ -54,11 +46,8 @@ subprojects {
5446
// Only configure the test task if it exists
5547
tasks.matching { it.name == "test" }.configureEach {
5648
if (this is Test) {
57-
finalizedBy(tasks.matching { it.name == "jacocoTestReport" })
49+
finalizedBy("jacocoTestReport")
5850
}
5951
}
6052
}
6153

62-
tasks.named("check") {
63-
dependsOn(reportTask)
64-
}

0 commit comments

Comments
 (0)