This is a collection of trivial functions to facilitate generating and exploring test coverage information for Julia packages locally, without using any remote/cloud services.
This package is not (yet) registered. You need to install it with
Pkg.clone("https://github.com/tpapp/LocalCoverage.jl.git")
Generating HTML needs the genhtml
utility, which is part of LCOV. On Debian/Ubuntu systems, use
sudo apt install lcov
Note that the code in this package assumes a reasonably recent lcov
version when calling genhtml
, ideally 1.13
, but 1.12
should work too. This only checked when building this package, and does not prevent installation, only emits a warning. See the discussion of issue #1 for a workaround.
using LocalCoverage
generate_coverage(pkg) # generate coverage information
open_coverage(pkg) # open in a browser
clean_coverage(pkg) # cleanup
Works fine with RoguePkg.jl for local packages.