Home

Awesome

kaocha-cloverage

<!-- badges -->

CircleCI cljdoc badge Clojars Project

<!-- /badges -->

Kaocha plugin to get code coverage reports through Cloverage.

<!-- opencollective -->

 

<img align="left" src="https://github.com/lambdaisland/open-source/raw/master/artwork/lighthouse_readme.png">

 

Support Lambda Island Open Source

kaocha-cloverage is part of a growing collection of quality Clojure libraries and tools released on the Lambda Island label. If you are using this project commercially then you are expected to pay it forward by becoming a backer on Open Collective, so that we may continue to enjoy a thriving Clojure ecosystem.

 

 

<!-- /opencollective -->

Installation

deps.edn

lambdaisland/kaocha-cloverage {:mvn/version "1.1.89"}

project.clj

[lambdaisland/kaocha-cloverage "1.1.89"]

Usage

Add the dependency

;; deps.edn
{:paths [...]
 :deps {...}
 :aliases
 {:test
  {:extra-deps {lambdaisland/kaocha {...}
                lambdaisland/kaocha-cloverage {...}}}}}

Enable the plugin

bin/kaocha --plugin cloverage
;; tests.edn
#kaocha/v1
{:plugins [:kaocha.plugin/cloverage]}

This plugin adds a large amount of command line options to Kaocha. Run bin/kaocha --plugin cloverage --help to see them.

Alternatively Cloverage can be configured through tests.edn. Source paths specified in your tests suites will be automatically instrumented. Other Cloverage options can be specified under a top level :cloverage/opts key. Run bin/kaocha --plugin cloverage --print-config to see the current default values.

;; tests.edn
#kaocha/v1
{:plugins [kaocha.plugin/cloverage]
 :cloverage/opts
 {:ns-exclude-regex [],
  :text? false,
  :lcov? false,
  :high-watermark 80,
  :fail-threshold 0,
  :output "target/coverage",
  :low-watermark 50,
  :ns-regex [],
  :summary? true,
  :coveralls? false,
  :emma-xml? false,
  :html? true,
  :nop? false,
  :codecov? false}}
<!-- contributing -->

Contributing

Everyone has a right to submit patches to kaocha-cloverage, and thus become a contributor.

Contributors MUST

Contributors SHOULD

If you submit a pull request that adheres to these rules, then it will almost certainly be merged immediately. However some things may require more consideration. If you add new dependencies, or significantly increase the API surface, then we need to decide if these changes are in line with the project's goals. In this case you can start by writing a pitch, and collecting feedback on it.

* This goes for features too, a feature needs to solve a problem. State the problem it solves, then supply a minimal solution.

** As long as this project has not seen a public release (i.e. is not on Clojars) we may still consider making breaking changes, if there is consensus that the changes are justified.

<!-- /contributing --> <!-- license -->

License

Copyright © 2018-2020 Arne Brasseur and contributors

Available under the terms of the Eclipse Public License 1.0, see LICENSE.txt

<!-- /license -->