-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.gradle
82 lines (71 loc) · 2.64 KB
/
main.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
allprojects {
repositories {
mavenCentral()
maven { url "https://repo.spring.io/snapshot" }
maven { url "https://repo.spring.io/milestone" }
}
}
subprojects {
apply plugin: 'java'
apply plugin: 'jacoco'
apply plugin: 'io.spring.dependency-management'
compileJava.dependsOn validateStructure
sourceCompatibility = JavaVersion.VERSION_17
test {
useJUnitPlatform()
}
dependencies {
implementation 'io.projectreactor:reactor-core'
implementation 'io.projectreactor.addons:reactor-extra'
testImplementation 'io.projectreactor.tools:blockhound-junit-platform:1.0.8.RELEASE'
testRuntimeOnly 'org.junit.platform:junit-platform-launcher'
testImplementation 'io.projectreactor:reactor-test'
testImplementation 'org.springframework.boot:spring-boot-starter-test'
compileOnly "org.projectlombok:lombok:${lombokVersion}"
annotationProcessor "org.projectlombok:lombok:${lombokVersion}"
testCompileOnly "org.projectlombok:lombok:${lombokVersion}"
testAnnotationProcessor "org.projectlombok:lombok:${lombokVersion}"
implementation platform("org.springframework.boot:spring-boot-dependencies:${springBootVersion}")
}
tasks.withType(Test).configureEach {
if (JavaVersion.current().isCompatibleWith(JavaVersion.VERSION_13)) {
jvmArgs += [
"-XX:+AllowRedefinitionToAddDeleteMethods"
]
}
}
test.finalizedBy(project.tasks.jacocoTestReport)
jacocoTestReport {
dependsOn test
reports {
xml.setRequired true
xml.setOutputLocation file("${buildDir}/reports/jacoco.xml")
csv.setRequired false
html.setOutputLocation file("${buildDir}/reports/jacocoHtml")
}
}
}
jacoco {
toolVersion = "${jacocoVersion}"
reportsDirectory = file("$buildDir/reports")
}
tasks.register('jacocoMergedReport', JacocoReport) {
dependsOn = [test, subprojects.jacocoTestReport]
additionalSourceDirs.setFrom files(subprojects.sourceSets.main.allSource.srcDirs)
sourceDirectories.setFrom files(subprojects.sourceSets.main.allSource.srcDirs)
classDirectories.setFrom files(subprojects.sourceSets.main.output)
executionData.setFrom project.fileTree(dir: '.', include: '**/build/jacoco/test.exec')
reports {
xml.setRequired true
csv.setRequired false
html.setRequired true
}
}
tasks.withType(JavaCompile).configureEach {
options.compilerArgs = [
'-Amapstruct.suppressGeneratorTimestamp=true'
]
}
tasks.named('wrapper') {
gradleVersion = '8.2.1'
}