-
Notifications
You must be signed in to change notification settings - Fork 2
/
build.gradle.kts
executable file
·55 lines (46 loc) · 1.18 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
import org.jetbrains.kotlin.gradle.plugin.mpp.AbstractKotlinNativeTargetPreset
val GROUP: String by project
val VERSION_NAME: String by project
group = GROUP
version = VERSION_NAME
plugins {
kotlin("multiplatform")
}
repositories {
jcenter()
}
kotlin {
jvm()
sourceSets {
val commonMain by getting {
dependencies {
implementation(deps.Kotlin.StdLib)
}
}
val jvmTest by getting {
dependencies {
implementation(deps.Kotlin.Test.Jvm)
implementation(deps.Spek.Dsl.Jvm)
runtimeOnly(deps.Spek.Runner.JUnit5)
}
}
val nativeMain by creating {
dependsOn(commonMain)
}
}
targets {
presets
.filterIsInstance<AbstractKotlinNativeTargetPreset<*>>()
.forEach { preset ->
targetFromPreset(preset, preset.name) {
compilations["main"].source(sourceSets["nativeMain"])
}
}
}
}
tasks.withType(Test::class) {
useJUnitPlatform {
includeEngines("spek2")
}
}
apply("$rootDir/gradle/gradle-mvn-mpp-push.gradle")