--reporter
optionThe progress and summary printed by Kaocha are done by one or more "reporter"
functions. A reporter can be specified with the --reporter
option followed
by a fully qualified function name.
Reporters in the kaocha.report
namespace can be specified without a
namespace prefix.
(ns my.project.reporter-test
(:require [clojure.test :refer :all]))
(deftest test-1
(is (= 1 0)))
(deftest test-2
(is true)
(is (throw (Exception. "")))
(is true))
(deftest test-3
(is true))
When I run bin/kaocha --reporter kaocha.report/documentation
And the output should contain:
my.project.reporter-test
test-1 FAIL
test-2 ERROR
test-3
When I run bin/kaocha --reporter documentation
Then the exit-code should be 2
And the output should contain:
my.project.reporter-test
test-1 FAIL
test-2 ERROR
test-3
When I run bin/kaocha --reporter does/not-exist
Then stderr should contain
ERROR: Failed to resolve reporter var: does/not-exist
Can you improve this documentation?Edit on GitHub
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close