hi folks, i have just started to work on an proje...
# kotest
a
hi folks, i have just started to work on an project that uses kotest in combination with the gradle org.unbroken-dome.test-sets plugin (1) The plugin allows to define additional test sourcesets (e.g. src/integrationTest/kotlin). I have now tried to use the IntelliJ kotest extension to be able to run the tests from the IDE. This works fine for the tests in the standard location (src/test/kotlin), however tests in the custom sourcesets are not beeing discovered by the IDE. Is this a known limitation of the extension or is there anything i can do to run the tests from the IDE? thanks in advance [1] https://plugins.gradle.org/plugin/org.unbroken-dome.test-sets Versions: IntelliJ version: IntelliJ IDEA 2024.3 (Ultimate Edition), Build #IU-243.21565.193, built on November 13, 2024 Plugin version: 1.3.86-243-EAP-SNAPSHOT kotest: 5.9.1
o
The gradle-testsets-plugin seems to target Java, so it is probably not integrated well enough with Kotlin's Gradle build tooling to be recognized by Kotest's IntelliJ plugin. If you are using the Kotlin Multiplatform Gradle plugin, it has its own capabilities of creating custom source sets: https://kotlinlang.org/docs/multiplatform-dsl-reference.html#custom-source-sets. Would that be an avenue you could follow?
e
Gradle’s
jvm-test-suite
plugin works fine if you only target JVM (haven’t tested KMP with it)
👍 2
👍🏾 1
a
thanks @Oliver.O and @Emil Kantis 🙏🏾 Using the `jvm-test-suite`plugin helped, i now can run the tests in the IDE. As we only need JVM support there is no benefit for us to use the KMP plugin.
👍 2