any reasons why post-summary would not be called at all?
I tried to add one but nothing was happening and even:
(post-summary [result]
(assert false))
doesn't blow up when I run kaocha.repl/run :something
also I was trying to find a way to go through the hierarchy more easily as discussed previously but I can't really find a way to do that (I mean I can come up with something but it seems overkill), here a simplified example:
;; how do I propagate the `retry? true` from :middle to :leaf?
;; or how do I look it up at runtime assuming I have
;; `:leaf, nested`
(def
nested
{:val 1
:id :root
:tests [{:val 1
:id :middle
:retry? true
:tests [{:val 2
:id :leaf}]}]})
post-summary
should be called from kaocha.repl/run
, if the CHANGELOG is to be believed 🙂
# 1.0.658 (2020-08-17 / 22ef88c)
- the post-summary
hook will also be called when invoked via kaocha.repl
mm I'm already on the latest version actually
ah yeah it works if I calls post-summary if I call it from the CLI
but not from kaocha.repl/run
(pre-test [testable test-plan]
(update testable :kaocha.test-plan/tests (partial map #(assoc % :retry? (:retry? testable)))
something like that
ah I see that I just needed to look in the top level, I thought that I needed a generic traversal from the leaf to the suite level testable
makes sense
mm maybe I have an older version