Open frenchy64 opened 3 years ago
If there's a refactoring that roughly preserves the current vanilla user experience, I'd be open to it.
Hmm, one way to achieve that might be if (thread-bound? #'ct/report)
, then propagate the reporting to individual test reports, otherwise keep the current format. I think the logic could be held in c.g.t.chuck.clojure-test/-report
.
It turns out
clojure.test/report
is very flexible, being both a dynamic var and a multimethod. I think introducing a custom reporting event via:type ::shrunk
is pretty much impossible to be compatible with this dynamism.For example, eftest has 3 different multimethods, all with different output formats: ANSI colors, xml, and progress bar. It dynamically rebinds
clojure.test/report
based on configuration parameters.What this means is the
::shrunk
printing disappears when the reporting mechanism is rebound. And since test.chuck can't predict what the current output format is, it seems wiser to piggieback the smallest+seed reporting on existing reporting types like:fail
or:pass
.