Big Chungus
02/10/2023, 4:34 PMjvmIntegrationTest
russhwolf
02/10/2023, 4:35 PMBig Chungus
02/10/2023, 4:51 PMjvm {
compilations {
val main by getting
val instrumentedTest by creating {
defaultSourceSet.dependsOn(main.defaultSourceSet)
}
val testTask = tasks.register<Test>("jvmInstrumentedTest") {
group = "verification"
classpath = instrumentedTest.runtimeDependencyFiles
}
tasks.named("allTests") { dependsOn(testTask) }
}
}
Big Chungus
02/10/2023, 5:07 PMcompilations {
val main by getting
val instrumentedTest by creating {
defaultSourceSet.dependsOn(main.defaultSourceSet)
}
val testTask = tasks.register<Test>("jvmInstrumentedTest") {
dependsOn(instrumentedTest.compileTaskProvider)
group = "verification"
classpath = instrumentedTest.runtimeDependencyFiles
testClassesDirs = instrumentedTest.defaultSourceSet.kotlin.sourceDirectories
}
tasks.named("allTests") { dependsOn(testTask) }
}
Big Chungus
02/10/2023, 5:19 PMClassNotFoundException
for the test class
compilations {
val main by getting
val instrumentedTest by creating {
defaultSourceSet.dependsOn(main.defaultSourceSet)
}
val testTask = tasks.register<Test>("jvmInstrumentedTest") {
dependsOn(instrumentedTest.compileTaskProvider)
group = "verification"
classpath =
instrumentedTest.compileDependencyFiles + instrumentedTest.runtimeDependencyFiles
testClassesDirs = instrumentedTest.output.classesDirs
shouldRunAfter("jvmTest")
testLogging { events("passed") }
}
tasks.named("allTests") { dependsOn(testTask) }
}
Big Chungus
02/10/2023, 5:26 PM