-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle.kts
102 lines (83 loc) · 3.44 KB
/
build.gradle.kts
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
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
plugins {
java
jacoco
id("org.springframework.boot") version "3.2.2"
id("io.spring.dependency-management") version "1.1.4"
id("org.springdoc.openapi-gradle-plugin") version "1.8.0"
id("org.openapi.generator") version "7.2.0"
kotlin("jvm") version "1.9.22"
kotlin("plugin.spring") version "1.9.22"
}
group = "com.sennproject"
version = "1.0.0"
java.sourceCompatibility = JavaVersion.VERSION_17
repositories {
mavenCentral()
}
extra["kotestVersion"] = "5.8.0"
extra["openAPIVersion"] = "1.7.0"
extra["testcontainersVersion"] = "1.19.4"
extra["coroutinesCoreVersion"] = "1.8.0-RC2"
dependencies {
implementation("org.springframework.boot:spring-boot-starter-data-r2dbc")
implementation("org.springframework.boot:spring-boot-starter-webflux")
implementation("com.fasterxml.jackson.module:jackson-module-kotlin")
implementation("io.projectreactor.kotlin:reactor-kotlin-extensions")
implementation("org.jetbrains.kotlin:kotlin-reflect")
implementation("org.jetbrains.kotlin:kotlin-stdlib-jdk8")
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-reactor")
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:${property("coroutinesCoreVersion")}")
implementation("org.springframework:spring-jdbc")
developmentOnly("org.springframework.boot:spring-boot-devtools")
implementation("org.springframework.boot:spring-boot-starter-actuator")
implementation("org.springframework.boot:spring-boot-configuration-processor")
// Lombok
compileOnly("org.projectlombok:lombok")
annotationProcessor("org.projectlombok:lombok")
// OpenAPI
implementation("org.springdoc:springdoc-openapi-kotlin:${property("openAPIVersion")}")
implementation("org.springdoc:springdoc-openapi-webflux-ui:${property("openAPIVersion")}")
// Database
implementation("io.asyncer:r2dbc-mysql:1.0.6")
runtimeOnly("com.mysql:mysql-connector-j:8.0.+")
implementation("org.springframework.data:spring-data-commons")
implementation("org.springframework.data:spring-data-relational")
// Test
testImplementation("io.kotest:kotest-runner-junit5:${property("kotestVersion")}")
testImplementation("io.kotest:kotest-assertions-core:${property("kotestVersion")}")
testImplementation("io.kotest:kotest-property:${property("kotestVersion")}")
testImplementation("org.jetbrains.kotlinx:kotlinx-coroutines-test:${property("coroutinesCoreVersion")}")
testImplementation("io.kotest.extensions:kotest-extensions-spring:1.1.3")
testImplementation("org.springframework.boot:spring-boot-starter-test")
testImplementation("org.springframework.boot:spring-boot-testcontainers")
testImplementation("io.projectreactor:reactor-test")
testImplementation("org.testcontainers:junit-jupiter")
testImplementation("org.testcontainers:mysql")
testImplementation("org.testcontainers:r2dbc")
// Faker
implementation("net.datafaker:datafaker:1.8.1")
}
dependencyManagement {
imports {
mavenBom("org.testcontainers:testcontainers-bom:${property("testcontainersVersion")}")
}
}
tasks.withType<KotlinCompile> {
kotlinOptions {
freeCompilerArgs = listOf("-Xjsr305=strict")
jvmTarget = "17"
}
}
tasks.withType<Test> {
useJUnitPlatform()
}
tasks.jacocoTestReport {
reports {
xml.required.set(true)
csv.required.set(false)
}
}
tasks.test {
finalizedBy(tasks.jacocoTestReport)
}