CanI have the JS Promise handling of `runTest {}` ...
# test
m
CanI have the JS Promise handling of
runTest {}
but not the delay-skipping behaviour? Delays are a part of the behaviour I want to test
e
I believe you can write a
suspend fun
or
Promise
-returning test function on KJS
m
Something like here?
e
but mocha and karma have pretty low test timeout values IIRC
m
I believe you can write a
suspend fun
or
Promise
-returning test function on KJS
I wanted to avoid the expect/actual but I guess that'd work 👍
t
Happened to stumble upon this thread, so in case this is still relevant for anyone: I’ve recently written a tiny library specifically for that: https://github.com/tomuvak/testing-coroutines. It provides a single function (called
asyncTest
) to replace
runTest
.