You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Essentially something like -m kaocha.runner --plugin cloverage works just fine to run tests and create a report.
But trying (kaocha.repl/run 'core-test {:plugins [:kaocha.plugin/cloverage]}) will just run the test without creating a report.
My interest in having this work is that I am following Juxt's example to get parallel testing out of kaocha and CircleCI as described at https://www.juxt.pro/blog/parallel-kaocha.
They use kaocha.repl/run in their example and I obviously don't want to have to run all my tests again just to produce a coverage report since the whole point of parallelization is to speed things up.
The text was updated successfully, but these errors were encountered:
mchughs
changed the title
Kaocha cloverage plugin doesn't create reports when used with with kaocha.repl/run
Kaocha cloverage plugin doesn't create reports when used with kaocha.repl/run
Aug 11, 2021
The cloverage plugin works a little different from other plugins, it implements that main hook, which fires right before we actually run the tests. It then takes over controls, hands it over to cloverage, and lets cloverage in turn invoke Kaocha again. In the end it throws a early-exit exception to stop Kaocha from running the tests again.
This main hook is not implemented in kaocha.repl/run. It would be a little hard to do while still maintaining the contract of kaocha.repl/run.
We don't recommend the approach that Juxt describes, Kaocha is getting its own first class parallelization support instead. We encourage you to try that out. See lambdaisland/kaocha#234
I have created a project below which minimally illustrates the issue. Please check it out and try running the two aliases.
https://github.com/mchughs/kaocha-cloverage-fail-example
Essentially something like
-m kaocha.runner --plugin cloverage
works just fine to run tests and create a report.But trying
(kaocha.repl/run 'core-test {:plugins [:kaocha.plugin/cloverage]})
will just run the test without creating a report.My interest in having this work is that I am following Juxt's example to get parallel testing out of kaocha and CircleCI as described at https://www.juxt.pro/blog/parallel-kaocha.
They use kaocha.repl/run in their example and I obviously don't want to have to run all my tests again just to produce a coverage report since the whole point of parallelization is to speed things up.
The text was updated successfully, but these errors were encountered: