David Nolen has recently released clojurescript 0.0-2496 with cljs.test included. Previously, I’ve never really got around to getting effective testing setup for clojurescript projects up and running so I thought I would take this as an opportunity to do so.
You can find a base setup here: cljsinit. You can clone this and run using: lein cljsbuild auto test
- You need leiningen, phantomjs (in your path)
- Setup a cljsbuild target for testing
- Use cljsbuild :notify-command to run phantomjs with a runner script (see phantom folder)
- Run using: lein cljsbuild auto test (test is just the name of the build target)
I plan to make a lein template for this at some point.