Closed pwoolcoc closed 2 years ago
I'm not aware of any current efforts, but I'd certainly welcome some discussion about it. My ideal solution would involve not baking the specifics of a particular coverage tool into nextest itself, and having some sort of inter-process protocol to communicate with a daemon as necessary instead.
turns out it works just fine with rustc
's built-in instrumentation and llvm's coverage tools. Repo is here: https://github.com/pwoolcoc/nextest-cov-example, output looks like:
I used the docs here to get this all working: https://doc.rust-lang.org/nightly/rustc/instrument-coverage.html
I'm working on integrating nextest with llvm-cov. https://github.com/taiki-e/cargo-llvm-cov/pull/144
If the above PR gets merged, generating coverage with nextest should be as simple as cargo llvm-cov nextest
@skyzh that's awesome! thank you
https://github.com/taiki-e/cargo-llvm-cov/pull/144 is now merged, maybe we can update docs and close this issue?
maybe we can update docs and close this issue?
Thanks again for getting this upstream! llvm-cov is one of several coverage tools one might want to use, so let's try and write up some generic documentation for this as well before closing this issue.
https://github.com/nextest-rs/nextest/pull/119 has more documentation + an example.
https://nexte.st/book/test-coverage.html has the documentation! Thanks everyone. If you've integrated nextest into your own coverage tool, please feel free to send a PR with documentation.
Is there any way to use this in conjunction with coverage tools? Maybe it would be better to go see if the coverage tool has support for this rather than the other way around, but if someone here has gotten nextest working with a coverage tool I'd love to hear about it.