Clojure Testing

Aug 2, 2016

Clojure start-up time can be expensive especially when using ClojureScript. Here’s a couple items I’ve used to cut down start-up test execution time down:

Run all namespaces

lein test

Run a specific namespace

lein test :only

Run a test case

lein test :only

Run in the REPL

lein repl
(use 'clojure.test)
(defn test-blog []
This is just a little helper function to make reloading and running the tests more efficient.
(require ' :reload-all)
(run-tests '