Skip to content

Commit

Permalink
added jacoco test coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
miguel-merlin committed Nov 23, 2024
1 parent 02c8137 commit ae6cb17
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ plugins {
id 'org.springframework.boot' version '3.2.3'
id 'io.spring.dependency-management' version '1.1.4'
id "com.diffplug.spotless" version "5.16.0"
id "jacoco"
id "application"
}

Expand Down Expand Up @@ -42,6 +43,20 @@ spotless {
}
}


jacocoTestReport {
dependsOn test
jacocoTestCoverageVerification {
violationRules {
rule {
limit {
minimum = 0.10
}
}
}
}
}

dependencies {
implementation 'org.springframework.boot:spring-boot-starter-data-jpa'
implementation 'org.springframework.boot:spring-boot-starter-web'
Expand All @@ -57,4 +72,5 @@ dependencies {

tasks.named('test') {
useJUnitPlatform()
finalizedBy jacocoTestCoverageVerification
}

0 comments on commit ae6cb17

Please sign in to comment.