plugins { id("org.springframework.boot") version "3.2.4" id("io.spring.dependency-management") version "1.1.4" jacoco kotlin("jvm") version "2.0.20" kotlin("plugin.jpa") version "1.9.23" kotlin("plugin.serialization") version "2.0.20" kotlin("plugin.spring") version "1.9.23" } group = "com.example" version = "0.0.1-SNAPSHOT" java { sourceCompatibility = JavaVersion.VERSION_17 } repositories { mavenCentral() } dependencies { implementation("com.fasterxml.jackson.module:jackson-module-kotlin") implementation("org.flywaydb:flyway-core") implementation("org.jetbrains.kotlin:kotlin-reflect") implementation("org.jetbrains.kotlinx:kotlinx-serialization-json") implementation("org.springframework.boot:spring-boot-starter-jdbc") implementation("org.springframework.boot:spring-boot-starter-mustache") implementation("org.springframework.boot:spring-boot-starter-web") developmentOnly("org.springframework.boot:spring-boot-devtools") runtimeOnly("org.postgresql:postgresql") testImplementation("org.jetbrains.kotlin:kotlin-test-junit5") testImplementation("org.mockito.kotlin:mockito-kotlin:5.4.0") testImplementation("org.springframework.boot:spring-boot-starter-test") } kotlin { compilerOptions { freeCompilerArgs.addAll("-Xjsr305=strict") apiVersion.set(org.jetbrains.kotlin.gradle.dsl.KotlinVersion.KOTLIN_1_7) } } tasks.withType { useJUnitPlatform() } tasks.test { finalizedBy(tasks.jacocoTestReport) // report is always generated after tests run } tasks.jacocoTestReport { dependsOn(tasks.test) // tests are required to run before generating the report }