1
1
plugins {
2
- id " com.github.spotbugs" version " 1.6.5"
3
- id " org.springframework.boot" version " 2.1.0.RELEASE"
2
+ id ' java'
3
+ id ' jacoco'
4
+ id ' checkstyle'
5
+ id ' eclipse'
6
+ id ' idea'
7
+ id " com.github.spotbugs" version " 1.6.6"
8
+ id " org.springframework.boot" version " 2.1.1.RELEASE"
4
9
id " io.spring.dependency-management" version " 1.0.6.RELEASE"
5
10
id " com.palantir.docker" version " 0.20.1"
6
- id " org.owasp.dependencycheck" version " 3.3.4"
7
11
id " org.sonarqube" version " 2.6.2"
8
12
id " com.gorylenko.gradle-git-properties" version " 1.5.2"
9
13
}
10
14
15
+
11
16
group = ' com.bnc'
12
17
version = ' 0.0.1-SNAPSHOT'
13
18
14
- apply plugin : ' java'
15
- apply plugin : ' jacoco'
16
- apply plugin : ' checkstyle'
17
- apply plugin : ' com.github.spotbugs'
18
- apply plugin : ' eclipse'
19
- apply plugin : ' idea'
20
-
21
19
sourceCompatibility = 1.8
22
20
targetCompatibility = 1.8
23
21
@@ -29,15 +27,15 @@ repositories {
29
27
}
30
28
31
29
spotbugs {
32
- toolVersion = ' 3.1.8 '
30
+ toolVersion = ' 3.1.10 '
33
31
}
34
32
35
33
jacoco {
36
34
toolVersion = " 0.8.2"
37
35
}
38
36
39
37
checkstyle {
40
- toolVersion ' 8.14 '
38
+ toolVersion ' 8.15 '
41
39
}
42
40
43
41
springBoot {
@@ -57,32 +55,6 @@ jacocoTestReport {
57
55
html. enabled true
58
56
csv. enabled false
59
57
}
60
-
61
- afterEvaluate {
62
- classDirectories = files(classDirectories. files. collect {
63
- fileTree(dir : it, exclude : [
64
- ' **/configuration/**'
65
- ])
66
- })
67
- }
68
- }
69
-
70
- jacocoTestCoverageVerification {
71
- afterEvaluate {
72
- classDirectories = files(classDirectories. files. collect {
73
- fileTree(dir : it, exclude : [
74
- ' **/configuration/**'
75
- ])
76
- })
77
- }
78
-
79
- violationRules {
80
- rule {
81
- limit {
82
- minimum = 0.8
83
- }
84
- }
85
- }
86
58
}
87
59
88
60
sonarqube {
@@ -99,7 +71,10 @@ test {
99
71
events " passed" , " skipped" , " failed"
100
72
}
101
73
102
- finalizedBy jacocoTestReport, jacocoTestCoverageVerification
74
+ jacoco {
75
+ excludes + = [ ' **/configuration/**' ]
76
+ }
77
+ finalizedBy jacocoTestReport
103
78
}
104
79
105
80
if (! project. hasProperty(" REPOSITORY_URI" )) {
@@ -117,22 +92,25 @@ docker {
117
92
buildArgs([' JAR_FILE' : " ${ bootJar.archiveName} " ])
118
93
}
119
94
95
+ dependencyManagement {
96
+ imports {
97
+ mavenBom " org.springframework.cloud:spring-cloud-sleuth:2.1.0.M2"
98
+ }
99
+ }
100
+
120
101
dependencies {
121
- def springBootVersion = ' 2.1.0.RELEASE'
122
- implementation group : ' org.springframework.boot' , name : ' spring-boot-starter-web' , version : springBootVersion
123
- implementation group : ' org.springframework.boot' , name : ' spring-boot-starter-actuator' , version : springBootVersion
124
- // Update this to release version and remove milestone repo
125
- implementation group : ' org.springframework.cloud' , name : ' spring-cloud-starter-sleuth' , version : ' 2.1.0.M1'
126
- implementation group : ' com.github.spotbugs' , name : ' spotbugs-annotations' , version : ' 3.1.8'
127
- implementation group : ' io.micrometer' , name : ' micrometer-registry-new-relic' , version : ' 1.1.0'
102
+ implementation group : ' org.springframework.boot' , name : ' spring-boot-starter-web'
103
+ implementation group : ' org.springframework.boot' , name : ' spring-boot-starter-actuator'
104
+ implementation group : ' org.springframework.cloud' , name : ' spring-cloud-starter-sleuth'
105
+ implementation group : ' com.github.spotbugs' , name : ' spotbugs-annotations' , version : ' 3.1.10'
106
+ implementation group : ' io.micrometer' , name : ' micrometer-registry-new-relic' , version : ' 1.1.1'
128
107
runtime group : ' org.postgresql' , name : ' postgresql' , version : ' 42.2.5'
129
108
130
- testImplementation group : ' org.springframework.boot' , name : ' spring-boot-starter-test' , version : springBootVersion
131
- testImplementation group : ' org.junit.jupiter' , name : ' junit-jupiter-api' , version : ' 5.3.1 '
109
+ testImplementation group : ' org.springframework.boot' , name : ' spring-boot-starter-test'
110
+ testImplementation group : ' org.junit.jupiter' , name : ' junit-jupiter-api' , version : ' 5.3.2 '
132
111
testImplementation group : ' org.assertj' , name : ' assertj-core' , version : ' 3.11.1'
133
- testImplementation group : ' org.mockito' , name : ' mockito-core' , version : ' 2.23.0'
134
- // Remove once Mockito 3.x gets released with Junit 5 support
135
- testImplementation group : ' org.mockito' , name : ' mockito-junit-jupiter' , version : ' 2.23.0'
136
- testRuntime group : ' org.junit.jupiter' , name : ' junit-jupiter-engine' , version : ' 5.3.1'
112
+ testImplementation group : ' org.mockito' , name : ' mockito-core' , version : ' 2.23.4'
113
+ testImplementation group : ' org.mockito' , name : ' mockito-junit-jupiter' , version : ' 2.23.4'
114
+ testRuntime group : ' org.junit.jupiter' , name : ' junit-jupiter-engine' , version : ' 5.3.2'
137
115
testRuntime group : ' com.h2database' , name : ' h2' , version : ' 1.4.197'
138
116
}
0 commit comments