-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
147 lines (130 loc) · 4.62 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
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
buildscript {
repositories {
mavenCentral()
maven {
url 'https://plugins.gradle.org/m2/'
}
}
dependencies {
classpath 'name.remal:gradle-plugins:1.5.1'
classpath 'org.sonarsource.scanner.gradle:sonarqube-gradle-plugin:3.4.0.2513'
classpath 'info.solidsoft.gradle.pitest:gradle-pitest-plugin:1.9.0'
classpath 'org.jetbrains.kotlin:kotlin-allopen:1.7.10'
classpath 'org.jetbrains.kotlin:kotlin-gradle-plugin:1.7.10'
classpath 'org.jetbrains.kotlin:kotlin-noarg:1.7.10'
classpath 'io.gitlab.arturbosch.detekt:detekt-gradle-plugin:1.21.0'
classpath 'org.jlleitschuh.gradle:ktlint-gradle:11.0.0'
}
}
plugins {
id 'io.spring.dependency-management' version '1.0.13.RELEASE'
}
allprojects {
repositories {
mavenCentral()
}
}
subprojects {
apply plugin: 'io.spring.dependency-management'
version '0.0.1-SNAPSHOT'
dependencyManagement {
dependencies {
dependency 'com.nhaarman.mockitokotlin2:mockito-kotlin:2.2.0'
dependencySet(group: 'io.cucumber', version: '7.8.0') {
entry 'cucumber-java'
entry 'cucumber-junit-platform-engine'
}
dependencySet(group: 'org.junit.jupiter', version: '5.9.0') {
entry 'junit-jupiter'
entry 'junit-jupiter-api'
entry 'junit-jupiter-engine'
entry 'junit-jupiter-params'
}
dependencySet(group: 'org.junit.platform', version: '1.9.0') {
entry 'junit-platform-commons'
entry 'junit-platform-engine'
entry 'junit-platform-launcher'
entry 'junit-platform-suite-api'
entry 'junit-platform-suite-commons'
entry 'junit-platform-suite-engine'
}
dependency 'org.mockito:mockito-core:4.8.0'
dependency 'org.pitest:pitest-junit5-plugin:1.0.0'
dependency 'org.pitest:pitest-command-line:1.9.5'
}
}
}
configure(subprojects) {
apply plugin: 'org.jetbrains.kotlin.jvm'
apply plugin: 'jacoco'
apply plugin: 'name.remal.sonarlint'
apply plugin: 'org.sonarqube'
apply plugin: 'info.solidsoft.pitest'
apply plugin: 'io.gitlab.arturbosch.detekt'
apply plugin: 'org.jlleitschuh.gradle.ktlint'
sourceCompatibility = 18
dependencies {
implementation 'org.jetbrains.kotlin:kotlin-stdlib-jdk8'
testImplementation 'io.cucumber:cucumber-java'
testImplementation 'io.cucumber:cucumber-junit-platform-engine'
testImplementation 'org.junit.jupiter:junit-jupiter'
testImplementation 'org.junit.jupiter:junit-jupiter-api'
testImplementation 'org.junit.jupiter:junit-jupiter-engine'
testImplementation 'org.junit.jupiter:junit-jupiter-params'
testImplementation 'org.junit.platform:junit-platform-commons'
testImplementation 'org.junit.platform:junit-platform-engine'
testImplementation 'org.junit.platform:junit-platform-suite-api'
testImplementation 'org.junit.platform:junit-platform-suite-commons'
testImplementation 'org.junit.platform:junit-platform-suite-engine'
testImplementation 'org.mockito:mockito-core'
pitest 'org.pitest:pitest-junit5-plugin'
pitest 'org.pitest:pitest-command-line'
}
jacoco {
toolVersion = "0.8.8"
}
jacocoTestCoverageVerification {
violationRules {
rule {
limit {
minimum = 1.0
}
}
}
}
check.dependsOn jacocoTestCoverageVerification
jacocoTestReport {
reports {
xml.enabled true
csv.enabled true
html.enabled true
}
}
test.finalizedBy jacocoTestReport
tasks.withType(org.jetbrains.kotlin.gradle.tasks.KotlinCompile).all {
kotlinOptions {
freeCompilerArgs = ['-Xjsr305=strict']
jvmTarget = '18'
}
}
ktlint {
version.set("0.45.2")
}
pitest {
targetClasses.set(['com.nelkinda.template.*']) // TODO change
pitestVersion.set('1.9.5')
timestampedReports.set(false)
testPlugin.set('junit5')
outputFormats.set(['XML', 'HTML'])
mutators.set(['DEFAULTS', 'STRONGER', 'CONSTRUCTOR_CALLS', 'INLINE_CONSTS', 'REMOVE_CONDITIONALS', 'REMOVE_INCREMENTS'])
mutationThreshold.set(100)
coverageThreshold.set(100)
}
test {
useJUnitPlatform()
}
}
wrapper {
gradleVersion '7.5.1'
distributionType = Wrapper.DistributionType.ALL
}