-
Notifications
You must be signed in to change notification settings - Fork 11
/
build.gradle.kts
68 lines (59 loc) · 2.21 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
import org.gradle.api.tasks.testing.logging.TestExceptionFormat
import org.gradle.api.tasks.testing.logging.TestLogEvent
plugins {
kotlin("jvm") version "1.9.25"
kotlin("plugin.spring") version "1.9.25"
id("org.springframework.boot") version "3.3.3"
id("io.spring.dependency-management") version "1.1.6"
}
java {
toolchain {
languageVersion = JavaLanguageVersion.of(21)
}
}
repositories {
mavenCentral()
}
dependencies {
implementation("org.springframework.boot:spring-boot-starter")
implementation("org.springframework.boot:spring-boot-starter-actuator")
implementation("org.springframework.boot:spring-boot-starter-jdbc")
implementation("org.springframework.boot:spring-boot-starter-jersey")
implementation("org.springframework.boot:spring-boot-starter-logging")
implementation("com.fasterxml.jackson.module:jackson-module-kotlin")
implementation("com.google.guava:guava:33.3.0-jre")
implementation("org.apache.commons:commons-lang3:3.16.0")
implementation("org.apache.httpcomponents:httpclient:4.5.14")
implementation("org.flywaydb:flyway-core")
implementation("org.flywaydb:flyway-database-postgresql")
implementation("org.jetbrains.kotlin:kotlin-reflect")
implementation("org.jooq:jooq:3.16.9")
implementation("org.slf4j:slf4j-api")
implementation("org.postgresql:postgresql")
testImplementation("org.junit.jupiter:junit-jupiter")
testImplementation("org.junit.jupiter:junit-jupiter-params")
testImplementation("org.hamcrest:hamcrest-library")
testImplementation("org.mockito.kotlin:mockito-kotlin:5.4.0")
testImplementation("org.springframework.boot:spring-boot-starter-test")
testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine")
}
tasks {
withType<Test> {
useJUnitPlatform()
testLogging {
displayGranularity = 1
showCauses = true
showStackTraces = true
exceptionFormat = TestExceptionFormat.FULL
events(TestLogEvent.PASSED, TestLogEvent.SKIPPED, TestLogEvent.FAILED)
}
reports.junitXml
val dbUrl = System.getenv("DB_URL")
if (dbUrl != null && dbUrl.isNotBlank()) {
systemProperty("DB_URL", dbUrl)
} else {
systemProperty("DB_URL", "jdbc:postgresql://localhost:5432/email_service?user=bob&password=dev")
}
systemProperty("spring.profiles.active", "development,test")
}
}