Does anybody know if current MPP plugin works with...
# multiplatform
a
Does anybody know if current MPP plugin works with JUnit5? I tried it, but did not manage it to work.
s
Do you mean just working with the JVM target? If so, it's entirely possible. I have it working with both my MPP projects.
a
Junit should work for JVM. Could you please share the build? I tried it, but it can't find any tests.
s
You need to tell Gradle to use JUnit Platform.
a
I tried to use
jvmTest
task for that, but it was not working. Also I see that you explicitely add
junit-jupiter
even if it is used internally in
kotlin-test-junit5
. I will try your solution. Thank you very much.
Yep. Seems to be working properly now. Thank you very much.
s
No problem :)
r
I have the same question but for Kotlin Multiplatform Mobile. I would like to use junit5 in
androidTest
or if possible
commonTest
. Couldn’t find any working example and I’m just starting with Gradle and Android Studio. Any hints? Thx!