-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathbuild.gradle.kts
More file actions
97 lines (85 loc) · 2.63 KB
/
build.gradle.kts
File metadata and controls
97 lines (85 loc) · 2.63 KB
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
plugins {
java
id("org.springframework.boot") version "2.7.11" apply false
id("io.spring.dependency-management") version "1.1.0" apply false
kotlin("jvm") apply false
kotlin("plugin.spring") apply false
id("jacoco")
}
allprojects {
group = "linkpool"
version = "0.1.0"
}
subprojects {
apply(plugin = "java")
apply(plugin = "org.jetbrains.kotlin.jvm")
apply(plugin = "org.jetbrains.kotlin.kapt")
repositories {
mavenCentral()
}
tasks.withType<Test> {
useJUnitPlatform()
}
java {
toolchain {
languageVersion.set(JavaLanguageVersion.of(11))
}
}
dependencies {
testImplementation("io.kotest:kotest-runner-junit5:_")
testImplementation("io.kotest.extensions:kotest-extensions-spring:_")
testImplementation("io.kotest:kotest-assertions-core:_")
testImplementation("io.kotest:kotest-property:_")
testImplementation("io.mockk:mockk:_")
testImplementation("com.ninja-squad:springmockk:_")
}
}
val asciidoctorExt: Configuration by configurations.creating
val snippetsDir by extra { "build/generated-snippets" }
tasks {
withType<Test> {
useJUnitPlatform()
}
test {
useJUnitPlatform()
outputs.dir(snippetsDir)
extensions.configure(JacocoTaskExtension::class) {
isEnabled = true
// destinationFile = layout.buildDirectory.file("jacoco/${name}.exec").get().asFile
includes = emptyList()
excludes = emptyList()
excludeClassLoaders = emptyList()
isIncludeNoLocationClasses = false
sessionId = "<auto-generated value>"
isDumpOnExit = true
classDumpDir = null
output = JacocoTaskExtension.Output.FILE
address = "localhost"
port = 6300
isJmx = false
}
}
jacocoTestReport {
reports {
// 원하는 리포트를 켜고 끌 수 있습니다.
html.isEnabled = true
xml.isEnabled = false
csv.isEnabled = false
// 각 리포트 타입 마다 리포트 저장 경로를 설정할 수 있습니다.
html.destination = file("$buildDir/jacocoHtml")
xml.destination = file("$buildDir/jacoco.xml")
}
}
jacocoTestCoverageVerification {
violationRules {
rule {
element = "CLASS"
limit {
counter = "BRANCH"
value = "COVEREDRATIO"
minimum = "0.50".toBigDecimal()
}
}
}
}
}