This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2015-11-02
Channels
- # admin-announcements (15)
- # aws (35)
- # beginners (6)
- # boot (183)
- # cider (51)
- # clara (17)
- # cljs-dev (32)
- # clojure (67)
- # clojure-dev (7)
- # clojure-india (1)
- # clojure-japan (3)
- # clojure-norway (1)
- # clojure-russia (26)
- # clojurescript (85)
- # clojurex (4)
- # community-development (1)
- # cursive (18)
- # data-science (1)
- # datomic (46)
- # devcards (29)
- # events (7)
- # funcool (21)
- # hoplon (10)
- # ldnclj (2)
- # lein-figwheel (16)
- # off-topic (60)
- # om (37)
- # onyx (8)
- # re-frame (23)
- # reagent (5)
- # yada (6)
@pandeiro we're currently ironing out that duplication on the prompt And a variable will be added to avoid the prompt altogether.
Cheers @malabarba @bozhidar - I'm trying to work around it by using a wrapper function that calls cider-connect
with the project root dir via projectile
that only runs them for the current namespace, lein test runs the whole test suite.
C-c , runs the command cider-test-run-tests, which is an interactive
compiled Lisp function in `cider-test.el'.
It is bound to C-c ,, <menu-bar> <CIDER> <Test> <Run all tests>.
(cider-test-run-tests SUPPRESS-INFERENCE)
Run all tests for the current Clojure source or test report context.
With a prefix arg SUPPRESS-INFERENCE it will try to run the tests in the
current ns.
yeah you are right. but the behavior i'm seeing is it only runs the corresponding tests for whichever buffer i'm in.
source confirms....
(defun cider-test-run-tests (suppress-inference)
"Run all tests for the current Clojure source or test report context.
With a prefix arg SUPPRESS-INFERENCE it will try to run the tests in the
current ns."
(interactive "P")
(if-let ((ns (if suppress-inference
(clojure-find-ns)
(or (funcall cider-test-infer-test-ns (clojure-find-ns))
(when (eq major-mode 'cider-test-report-mode)
cider-test-last-test-ns)))))
(cider-test-execute ns nil)
(message "No namespace to test in current context")))
I actually prefer the behavior the way it is, but I routinely run lein test like a good dev before I push, and was just curious if I could do the equivalent with cider, since it would make it easier to jump to problem areas. I guess if I run it in a compile buffer I get some of that back.
I have my tests running automatically in the background on save so I’ve never used CIDER to do it.
ideally one could just run M-x compile with lein test-refresh but the output doesnt get parsed right to make niceties like jumping to where the error occurred possible
I planned on adding it directly to Emacs, but the compile.el code is... complicated
running the tests for all files in the project would require a somewhat different approach compared to the one we use now
besides, I think if the user has refactor-nrepl set up, then "loaded namespaces" ends up being equal to "all namespaces"
@malabarba: Sorry, I didn't mention your question
>Issue M-x customize-variable RET cider-cljs-repl if you'd like to change the REPL used (the default is rhino).
>IllegalArgumentException No value supplied for key: [email protected] clojure.lang.PersistentHashMap.create (PersistentHashMap.java:77)