fix/pipeline #16

Closed
bquarkz wants to merge 16 commits from fix/pipeline into master
2 changed files with 30 additions and 22 deletions
Showing only changes of commit b3e3a68736 - Show all commits

6
Jenkinsfile vendored
View File

@ -16,9 +16,9 @@ pipeline {
recordCoverage(tools: [[parser: 'JACOCO']], recordCoverage(tools: [[parser: 'JACOCO']],
id: 'jacoco', name: 'JaCoCo Coverage', id: 'jacoco', name: 'JaCoCo Coverage',
sourceCodeRetention: 'EVERY_BUILD' sourceCodeRetention: 'EVERY_BUILD'
// , qualityGates: [ , qualityGates: [
// [threshold: 60.0, metric: 'LINE', baseline: 'PROJECT', unstable: true], [threshold: 40.0, metric: 'LINE', baseline: 'PROJECT', unstable: true],
// [threshold: 60.0, metric: 'BRANCH', baseline: 'PROJECT', unstable: true]] [threshold: 40.0, metric: 'BRANCH', baseline: 'PROJECT', unstable: true]]
) )
} }
} }

View File

@ -37,28 +37,36 @@ jacoco {
toolVersion = "0.8.12" toolVersion = "0.8.12"
} }
tasks.jacocoTestCoverageVerification { tasks.jacocoTestReport {
violationRules { reports {
rule { xml.required = true
limit { csv.required = false
minimum = "0.4".toBigDecimal() html.required = false
}
}
rule {
isEnabled = false
element = "CLASS"
includes = listOf("jenkins.test.*")
limit {
counter = "LINE"
value = "TOTALCOUNT"
maximum = "0.3".toBigDecimal()
}
}
} }
} }
//tasks.jacocoTestCoverageVerification {
// violationRules {
// rule {
// limit {
// minimum = "0.4".toBigDecimal()
// }
// }
//
// rule {
// isEnabled = false
// element = "CLASS"
// includes = listOf("jenkins.test.*")
//
// limit {
// counter = "LINE"
// value = "TOTALCOUNT"
// maximum = "0.3".toBigDecimal()
// }
// }
// }
//}
application { application {
// Define the main class for the application. // Define the main class for the application.
mainClass.set("jenkins.test.App") mainClass.set("jenkins.test.App")