-
Notifications
You must be signed in to change notification settings - Fork 2
/
build.gradle.kts
96 lines (80 loc) · 3.47 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
import com.diffplug.gradle.spotless.SpotlessExtension
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
plugins {
val kotlinVersion = "2.1.0"
kotlin("jvm") version kotlinVersion
kotlin("plugin.spring") version kotlinVersion
kotlin("plugin.jpa") version kotlinVersion
id("org.springframework.boot") version "3.4.0"
id("io.spring.dependency-management") version "1.1.0"
id("me.qoomon.git-versioning") version "6.4.1"
id("com.diffplug.spotless") version "6.25.0"
id("jacoco")
}
group = "com.stefanbratanov"
version = "develop"
gitVersioning.apply {
refs {
tag("v(?<version>.*)") { version = "\${ref.version}" }
rev { version = "develop" }
}
}
java {
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
}
jacoco { toolVersion = "0.8.8" }
repositories { mavenCentral() }
// version compatible with PhantomJS
val seleniumVersion = "4.8.1"
// https://docs.spring.io/spring-boot/appendix/dependency-versions/properties.html
extra["selenium.version"] = seleniumVersion
val junitVersion = "5.11.0"
extra["junit-jupiter.version"] = junitVersion
dependencies {
implementation("org.springframework.boot:spring-boot-starter-web")
implementation("org.springframework.boot:spring-boot-starter-actuator")
implementation("org.springframework.data:spring-data-keyvalue")
implementation("org.springframework.boot:spring-boot-starter-data-jpa")
implementation("org.springframework.boot:spring-boot-starter-cache")
implementation("org.springframework.boot:spring-boot-starter-validation")
implementation("org.postgresql:postgresql")
implementation("org.springdoc:springdoc-openapi-starter-webmvc-ui:2.7.0")
implementation("org.jetbrains.kotlin:kotlin-reflect")
implementation("org.jetbrains.kotlin:kotlin-stdlib")
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:1.10.1")
implementation("com.fasterxml.jackson.module:jackson-module-kotlin")
implementation("org.apache.commons:commons-lang3")
implementation("com.fasterxml.jackson.datatype:jackson-datatype-jsr310")
implementation("org.apache.commons:commons-math3:3.6.1")
implementation("org.jsoup:jsoup:1.18.1")
implementation("org.apache.pdfbox:pdfbox:3.0.0")
implementation("me.xdrop:fuzzywuzzy:1.4.0")
implementation("com.cloudinary:cloudinary-http45:1.39.0")
implementation("org.seleniumhq.selenium:selenium-java:$seleniumVersion")
implementation("com.codeborne:phantomjsdriver:1.5.0")
implementation("io.github.bonigarcia:webdrivermanager:4.4.3") // no PhantomJS driver in 5.x.x
testImplementation("org.junit.jupiter:junit-jupiter:$junitVersion")
testImplementation("org.springframework.boot:spring-boot-starter-test")
testImplementation("com.willowtreeapps.assertk:assertk-jvm:0.28.0")
testImplementation("io.mockk:mockk:1.13.4")
testImplementation("com.ninja-squad:springmockk:4.0.0")
testImplementation("org.skyscreamer:jsonassert:1.5.1")
testImplementation("org.mock-server:mockserver-spring-test-listener:5.15.0")
testRuntimeOnly("com.h2database:h2")
}
springBoot { buildInfo() }
// dont't produce *-plain.jar
tasks.getByName<Jar>("jar") { enabled = false }
tasks.withType<KotlinCompile> {
kotlinOptions {
freeCompilerArgs = listOf("-Xjsr305=strict", "-Xjvm-default=all-compatibility")
jvmTarget = "17"
}
}
tasks.withType<Test> {
useJUnitPlatform()
testLogging { showStandardStreams = true }
}
configure<SpotlessExtension> { kotlin { ktfmt("0.53").googleStyle() } }
tasks.jacocoTestReport { reports { xml.required.set(true) } }