5be88b306c
- Updated Gradle version in `.env`, Dockerfiles, and wrapper to 9.3.1. - Replaced alias-based application of `kotlinMultiplatform` plugin with direct `id` usage in subprojects to resolve "Plugin loaded multiple times" error. - Applied centralized plugin management and Gradle daemon optimizations to improve Docker build stability and address KMP classloading issues.
75 lines
1.6 KiB
Kotlin
75 lines
1.6 KiB
Kotlin
plugins {
|
|
// Fix for "Plugin loaded multiple times": Apply plugin by ID without version (inherited from root)
|
|
id("org.jetbrains.kotlin.multiplatform")
|
|
alias(libs.plugins.kotlinSerialization)
|
|
}
|
|
|
|
kotlin {
|
|
jvm {
|
|
compilerOptions {
|
|
freeCompilerArgs.add("-opt-in=kotlin.time.ExperimentalTime")
|
|
}
|
|
}
|
|
|
|
js(IR) {
|
|
binaries.library()
|
|
// Re-enabled browser environment after Root NodeJs fix
|
|
browser {
|
|
testTask {
|
|
enabled = false
|
|
}
|
|
}
|
|
}
|
|
|
|
@OptIn(org.jetbrains.kotlin.gradle.ExperimentalWasmDsl::class)
|
|
wasmJs {
|
|
binaries.library()
|
|
browser()
|
|
}
|
|
|
|
sourceSets {
|
|
all {
|
|
languageSettings.optIn("kotlin.uuid.ExperimentalUuidApi")
|
|
languageSettings.optIn("kotlin.time.ExperimentalTime")
|
|
}
|
|
|
|
commonMain.dependencies {
|
|
api(libs.kotlinx.serialization.json)
|
|
api(libs.kotlinx.datetime)
|
|
}
|
|
|
|
commonTest.dependencies {
|
|
implementation(libs.kotlin.test)
|
|
}
|
|
|
|
jsMain.dependencies {
|
|
api(libs.kotlinx.coroutines.core)
|
|
}
|
|
|
|
jsTest.dependencies {
|
|
implementation(libs.kotlin.test)
|
|
}
|
|
|
|
jvmMain.dependencies {
|
|
}
|
|
|
|
jvmTest.dependencies {
|
|
implementation(libs.junit.jupiter.api)
|
|
implementation(libs.mockk)
|
|
implementation(projects.platform.platformTesting)
|
|
implementation(libs.junit.jupiter.api)
|
|
implementation(libs.junit.jupiter.engine)
|
|
implementation(libs.junit.jupiter.params)
|
|
implementation(libs.junit.platform.launcher)
|
|
implementation(libs.mockk)
|
|
implementation(libs.assertj.core)
|
|
implementation(libs.kotlinx.coroutines.test)
|
|
}
|
|
|
|
}
|
|
}
|
|
|
|
tasks.named<Test>("jvmTest") {
|
|
useJUnitPlatform()
|
|
}
|