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

Big Chungus

11/01/2021, 3:48 PM
Is there an example of kotest framework mpp setup somewhere?
b

Big Chungus

11/01/2021, 3:54 PM
I have that exact setup yet I'm getting
Copy code
Caused by: org.junit.platform.commons.PreconditionViolationException: Cannot create Launcher without at least one TestEngine; consider adding an engine implementation JAR to the classpath
j

Jim

11/01/2021, 3:56 PM
Can you try adding the engine-jvm dependency to your jvm deps and the engine-js to the js one? I noticed this on my project last week and thought it was something I had done. If that works for you we can track down what's going on
b

Big Chungus

11/01/2021, 3:56 PM
is engine dep in commonTest not sufficient?
j

Jim

11/01/2021, 3:57 PM
I thought it was but perhaps it's not, I'll be on my work computer in 30 to check my project
b

Big Chungus

11/01/2021, 3:58 PM
Do I still need junit5 runner for jvmTest too?
j

Jim

11/01/2021, 3:58 PM
I have that
b

Big Chungus

11/01/2021, 3:59 PM
Nope, same shit
What gradle plugin and lib versions do you use?
j

Jim

11/01/2021, 4:00 PM
🤔 ok I'll check in a bit, I'm using 5. M2
I think gradle 6.7.1
b

Big Chungus

11/01/2021, 4:00 PM
I'm on io.kotest.multiplatform:5.0.0.5 & lib:5.0.0.M3
j

Jim

11/01/2021, 4:01 PM
Ok I'll bump to m3 and see if that's it
b

Big Chungus

11/01/2021, 4:13 PM
Nvm, figured it out. There was race condition in my gradle scripts. Everything works now.
Well not everything, nested testing in js is still not supported, unfortunatelly
j

Jim

11/01/2021, 4:34 PM
Ah cool, do you not need the specific engines listed?
b

Big Chungus

11/01/2021, 4:36 PM
No, just common is enough
s

sam

11/01/2021, 6:13 PM
nested testing will never work on JS unfortunately, as the outer scopes in karma/mocha don't support async
b

Big Chungus

11/01/2021, 6:48 PM
I see, thanks for clarifying. Would be good to have some table in the docs outlining what does and doesn't work on js, tho.
👍 1
👍🏻 1
j

Jim

11/01/2021, 6:49 PM
Maybe we need multiplatspec
2 Views