@thomasmoerman has joined the channel
I have a weird minor issue with kaocha tests with watching enabled: the suite is executed twice instead of once on change of a source file. Anyone a clue as to why this happens?
That's odd. My first thought would normally be that your namespace includes something like (clojure.test/run-tests) inside it.
Since it only happens with --watch , it could be due to your editor (or some other process) modifying some temporary file that Kaocha is watching for some reason.
Please share your tests.edn, there are some patterns that we don't recommend
{:kaocha/tests [{:kaocha.testable/type :kaocha.type/clojure.test
:kaocha.testable/id :unit
:kaocha/ns-patterns ["-test$"]
:kaocha/test-paths ["src/test"]
:kaocha/source-paths ["src/main"]
:kaocha.filter/focus [
;; ... more ...
"nexus.core.model.stonepath-test"
;; ... more ...
]}]
:kaocha/reporter [;kaocha.report/dots
fulcro-spec.reporters.terminal/fulcro-report
]
:kaocha/fail-fast? false
:kaocha/color? true
:kaocha/plugins [:kaocha.plugin/filter ;; allows focus filter - comment out to run ALL tests
;:kaocha.plugin/print-invocations
;:kaocha.plugin/debug
;:kaocha.plugin/capture-output
;:kaocha.plugin/profiling
]
:kaocha.plugin.profiling/count 1
:kaocha.plugin.profiling/profiling? false
:kaocha.plugin.randomize/randomize? false}@actuallyalys_slack that's the direction I'm searching in, I probably need to dig a little deeper. @plexus yes, I usually run with a focus.
Made some progress: running twice on save is probably caused by an IntelliJ setting:
however the assertion count is sometimes 2x what I expect, possibly related to this issue: https://github.com/lambdaisland/kaocha/issues/245 Not a big problem for me though, so I'm going to stop digging for now ;-)
Fair enough. 🙂 Let us know if you find any bugs or need further troubleshooting help! If it is due to #245, then it should be fixed by upgrading to the latest Kaocha.
Do you have tests suites defined with skip/focus?
@nha has joined the channel