added mutation testing with pitest as a separate task (too slow because there are almost only IntTests)

This commit is contained in:
Michael Hoennig 2019-04-11 14:34:19 +02:00
parent 19c0049b0e
commit 4fdcf77e8e

View File

@ -60,22 +60,6 @@ dependencyManagement {
}
}
pitest {
targetClasses = ['org.hostsharing.hsadminng.*']
excludedClasses = ['*IntTest']
threads = 4
// Do not set these limit even lower, they are already pretty bad values!
// 83%*73% means that only ~60% of the code properly covered by automated tests.
mutationThreshold = 73
coverageThreshold = 83
timeoutFactor = 3.0
outputFormats = ['XML', 'HTML']
timestampedReports = false
verbose = false
}
defaultTasks 'bootRun'
group = 'org.hostsharing.hsadminng'
@ -137,7 +121,6 @@ jacoco {
test.finalizedBy jacocoTestReport
check.dependsOn jacocoTestCoverageVerification
check.dependsOn 'pitest'
// Only for purely JHipster/MapStruct generated classes.
// Please do NOT add any self coded classes!
@ -221,6 +204,22 @@ task cucumberTestReport(type: TestReport) {
reportOn cucumberTest
}
// --- PiTest mutation testing ---
pitest {
targetClasses = ['org.hostsharing.hsadminng.*']
threads = 4
// Do not set these limit even lower, they are already pretty bad values!
// 83%*73% means that only ~60% of the code properly covered by automated tests.
mutationThreshold = 73
coverageThreshold = 83
outputFormats = ['XML', 'HTML']
timestampedReports = false
verbose = false
}
// ------------------------------
apply from: 'gradle/docker.gradle'