build: added jacoco coverage support
This commit is contained in:
parent
6f19056fde
commit
21536b9151
@ -2,6 +2,7 @@ plugins {
|
||||
id 'java'
|
||||
id 'idea'
|
||||
id "org.sonarqube" version "3.2.0"
|
||||
id 'jacoco'
|
||||
}
|
||||
|
||||
repositories {
|
||||
@ -15,6 +16,26 @@ test {
|
||||
maxParallelForks = 1
|
||||
}
|
||||
|
||||
jacocoTestReport {
|
||||
reports {
|
||||
html.enabled true
|
||||
xml.enabled true
|
||||
xml.destination file("${buildDir}/reports/jacoco.xml")
|
||||
}
|
||||
}
|
||||
|
||||
plugins.withType(JacocoPlugin) {
|
||||
tasks["test"].finalizedBy 'jacocoTestReport'
|
||||
}
|
||||
|
||||
sonarqube {
|
||||
properties {
|
||||
property "sonar.java.coveragePlugin", "jacoco"
|
||||
property "sonar.host.url", "https://sonarqube.yandrik.dev"
|
||||
property "sonar.coverage.jacoco.xmlReportPath", "${buildDir}/reports/jacoco.xml"
|
||||
}
|
||||
}
|
||||
|
||||
var mainClassName = "uulm.teamname.marvelous.server.Server"
|
||||
|
||||
jar {
|
||||
|
Loading…
Reference in New Issue
Block a user