lambdaisland / kaocha-cljs2

Run ClojureScript tests from Kaocha (major rewrite)
Mozilla Public License 2.0
26 stars 10 forks source link

timeout not respected in all cases #31

Open henryw374 opened 1 year ago

henryw374 commented 1 year ago

hello. in the config you can specify :kaocha.cljs2/timeout xxx and that gets passed through to the funnel client listen! function https://github.com/lambdaisland/kaocha-cljs2/blob/main/src/kaocha/cljs2/funnel_client.clj#L53 for the 'load' of the tests from the initial config. when it comes to the next stage of loading - getting tests from the clients, the timeout is not passed on - it is nil.

Note. this description ^^^ might not be quite right. the process of loading and running in kaocha is not completely clear to me. but the first time listen! is called the timeout is there, and the next time it is nil - that I can say for sure

so... in an attempt to get my suites passing I have changed this line in my branch https://github.com/henryw374/kaocha-cljs2/blob/main/src/kaocha/type/cljs2.clj#L99 - to call add-timeouts before the load. this seems to work...

lambduhh commented 5 months ago

Hello Henry,

First off, thank you very much for bringing this issue to our attention and for the effort you've put into investigating it. Your detailed description has been incredibly helpful in understanding the nuanced behavior regarding timeout settings during the test execution process. We appreciate the time you've taken to dive into this and share your findings with us.

Based on your report and a thorough review of the code, I identified a few areas that could be contributing to the inconsistency in timeout propagation you've observed. Specifically, the management of hierarchical timeouts and the passing of these timeout settings through various stages of test loading and execution present areas that warrant closer examination.

Have you been using your fix branch successfully since you made the report?

We're committed to resolving this issue and will keep you updated on our progress. In the meantime, if you have any further insights, suggestions, or questions, please don't hesitate to share them. Your input is invaluable to us as we work towards a solution.

Thank you once again for your contribution and for helping improve the reliability and functionality of kaocha for cljs We're looking forward to resolving this together.

Happy hacking!

henryw374 commented 5 months ago

Hi Jordan. thanks for looking into it!

yes I have successfully been using my branch for test suites which would otherwise timeout