-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
79 lines (67 loc) · 1.56 KB
/
build.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
plugins {
id 'java'
id 'eclipse-wtp'
id 'org.sonarqube' version '3.3'
}
group 'it.francescofiora'
version = '1.0-SNAPSHOT'
allprojects {
repositories {
mavenLocal()
mavenCentral()
}
sourceCompatibility = 1.11
targetCompatibility = 1.11
}
subprojects {
apply plugin: 'java'
apply plugin: 'eclipse-wtp'
apply plugin: 'checkstyle'
apply plugin: 'jacoco'
sourceCompatibility = 1.11
targetCompatibility = 1.11
group = rootProject.group
version = rootProject.version
checkstyle {
toolVersion property('checkstyle.version')
configFile rootProject.file("config/checkstyle/checkstyle.xml")
configProperties = [
'checkstyle.cache.file': "${buildDir}/checkstyle.cache",
]
}
tasks.withType(Checkstyle) {
reports {
xml.enabled = false
html.enabled = true
}
}
checkstyleMain {
source ='src/main/java'
}
test {
useJUnitPlatform()
finalizedBy jacocoTestReport
}
jacocoTestReport {
dependsOn test
reports {
xml.enabled true
csv.enabled false
html.destination file("${buildDir}/reports/jacoco/test")
xml.destination file("${buildDir}/reports/jacoco/test/jacocoTestReport.xml")
}
}
sonarqube {
properties {
property "sonar.sourceEncoding", "UTF-8"
property 'sonar.core.codeCoveragePlugin', 'jacoco'
property 'sonar.coverage.jacoco.xmlReportPaths', "${buildDir}/reports/jacoco/test/jacocoTestReport.xml"
}
}
task cleanResources(type: Delete) {
delete "build/resources"
}
}
wrapper {
gradleVersion = "7.0"
}