-
Notifications
You must be signed in to change notification settings - Fork 1.9k
/
Copy pathbuild.gradle.kts
64 lines (47 loc) · 1.59 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
@file:Suppress("PropertyName")
plugins {
kotlin("jvm")
}
val coroutines_version: String by project
repositories {
if (project.properties["build_snapshot_train"]?.toString()?.toBoolean() == true) {
maven("https://maven.pkg.jetbrains.space/kotlin/p/kotlin/dev")
}
mavenLocal()
mavenCentral()
}
java {
modularity.inferModulePath.set(true)
}
kotlin {
jvmToolchain(17)
val test = target.compilations.getByName("test")
target.compilations.create("debugDynamicAgentJpmsTest") {
associateWith(test)
defaultSourceSet.dependencies {
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:$coroutines_version")
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-debug:$coroutines_version")
}
tasks.register<Test>("debugDynamicAgentJpmsTest") {
testClassesDirs = output.classesDirs
classpath = javaSourceSet.runtimeClasspath
}
}
target.compilations.create("externalStaticDebugProbesTest") {
associateWith(test)
defaultSourceSet.dependencies {
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:$coroutines_version")
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-debug:$coroutines_version")
}
tasks.register<Test>("externalStaticDebugProbesTest") {
testClassesDirs = output.classesDirs
classpath = javaSourceSet.runtimeClasspath
}
}
}
tasks.named("check") {
dependsOn(tasks.withType<Test>())
}
dependencies {
testImplementation(kotlin("test-junit"))
}