I'm trying to setup testing. This is the commit w...
# compose-web
e
I'm trying to setup testing. This is the commit where I tried adding a test (it should fail on purpose, just to check that testing works:
assertTrue(false)
): https://github.com/erikhuizinga/ranstax/commit/b6bbd063fbc422e18a4cfb0962bb362a27216bd1 However, when I run
./gradlew check
, the output is
BUILD SUCCESSFUL
and I see some error log that doesn't lead to a Gradle task failure:
Copy code
> Task :composeApp:wasmJsBrowserTest
Module not found: Error: Can't resolve './skiko.mjs' ...
What's going on here?
o
test configuration is quite verbose for CfW now. Here is an example in our resources library - https://github.com/JetBrains/compose-multiplatform/pull/4031 + there was a fix after 1.6.0-alpha01 specifically for tests. you'll need to use the recent dev build
gratitude thank you 1
e
Thanks Oleksandr! I got it working, but I had to use
v1.6.0-dev1362
(or the previous dev version found here: https://maven.pkg.jetbrains.space/public/p/compose/dev/org/jetbrains/compose/components/components-resources-wasmJs/) to make it work. Here's the commit: https://github.com/erikhuizinga/ranstax/commit/10f552f6a7de060b38af18f8ac5e264cb6761b08 It does seem that tests are run twice. And, interestingly, the two tests that I've added that should fail, fail with a yellow X in one run and with a red ! in the other, e.g. see screenshot.
o
Could you please file a ticket to k/wasm regarding the tests execution?