https://kotlinlang.org logo
#kotest
Title
# kotest
k

Kirill Zhukov

09/06/2023, 8:22 PM
I have a custom
integrationTest
compilation in KMP project and a JVM target. I’ve got some tests in
jvmIntegrationTest
source set. When trying to run these tests from IDE using Kotest plugin, it seems to run
jvmTest
task not
jvmIntegrationTest
. Is it something that Kotest plugin need to somehow pick up on, or are there additional steps I need to take when configuring my compilation? 👀
IDE highlights the source set green as test just fine.
Configuration is configured like so:
Untitled
And source sets:
Untitled
With
configureJunit
function like this:
Copy code
private fun Project.configureJUnit(sourceSet: KotlinSourceSet) {
  sourceSet.apply {
    tasks.withType<Test>().configureEach {
      useJUnitPlatform()
      configureJvmTestLogging()
      propagateKotestSystemProperties()
    }

    dependencies {
      implementation(libs.jvm.test.kotest.junit)
    }
  }
}
j

Javier

09/06/2023, 11:32 PM
your integrationTest configurations work with all targets?
k

Kirill Zhukov

09/06/2023, 11:34 PM
Only with JVM today
Any ideas on what would be a sensible fix here? We would probably want to filter tests using a test type or something instead of a task name?
15 Views