Open crisptrutski opened 9 years ago
I've thought about the following:
lein doo slimer test only ns/test-1 ns/test-2
lein doo slimer test only ns1 ns2
Would that cover your needs? Otherwise, we can always extend doo
's api to have doo-test-vars
and doo-test-var
in place of cljs.test/test-vars
and cljs,test/test-var
.
We'll add support for doo-test-vars
and doo-test-var
when cljs-1267 is finalized. The only
option from the command line will be treated separately.
Seems cljs-1267 issue has landed. Would be great to have this! @bensu If you don't have cycles for this let us know and hopefully one of us can get to it
Thanks @cldwalker, I forgot about this.
Before encouraging you to go for it, I must warn you that it is not as straight forward as it sounds for three reasons:
cljs.test/test-var
, cljs.test/test-vars
, cljs.test/run-tests
(the reason why in CLJS-1267 I wanted to keep them the same was to facilitate this future!)(doo-test-var 'one.ns/test)
followed by (doo-run-tests 'other.ns 'yet-another.ns)
. How should that be implemented? For this feature, I would keep it as it is, with only one top level doo
form.cljs.test/report
multimethods will make #43 hader, or when implementing that, the work for this will be refactored.So, having those three things in mind, I encourage anybody who wants to give it a shot, provided that they understand that the work might be somewhat refactored in the future due to 2 and 3. Otherwise I'll handle this myself after sorting out all bug/setup issues.
It would be convenient to be able to run only specific tests, rather than whole namespaces. This would be particularly useful with downstream tooling eg. rerunning failing tests first on save, or only the tests that call the given function.
Expect the method would take vars, ie.
(doo-test-vars #'ns/test-1 #'ns/test-2)
, as I don't believe something likeresolve
exists in Clojurescript.