Wednesday, February 10, 2016

[ClojureScript] Run all tests in multiple namespaces in REPL

From ClojureScript wiki, it says
If you have many test namespaces it's idiomatic to create a test runner namespace which imports all of your test namespaces and then invokes run-tests
I personally couldn't get it to work. Though I have managed to make run-all-tests works. This is an example

(ns myns.test.runner
  (:require [cljs.test :refer-macros [run-all-tests]]
            [myns.test.ns1]
            [myns.test.ns2]))

(run-all-tests #"myns.test.*")

No comments:

Clojure how to get JVM options from inside application

(.getInputArguments (java.lang.management.ManagementFactory/getRuntimeMXBean)) Credit:  How to get vm arguments from inside of java applic...