How to work with coverage data

Christian Köstlin christian.koestlin at gmail.com
Sun Jul 31 20:52:51 UTC 2022


Hi dlang lovers,

I recently wanted to improve how I work with coverage data (locally).

For that I came up with a small program, that can be either called after 
a `dub test --coverage` or that can be automatically executed after the 
unittest with `postRunCommands "$DUB run lst2errormessages"` in 
`dub.sdl` and that converts the generated lst files to error messages 
compatible with dmd output.

That way you can integrate them into your favorite editor, if it already 
has some dmd error output support. I use it mainly in emacs compile-mode 
or flycheck-mode (the latter with another small addition), but its also 
possible to run this in vscode + d-code.

Is there any interest in a more detailed write up of this.

Anyways, the code is available at 
https://gitlab.com/gizmomogwai/lst2errormessages

Kind regards,
Christian


More information about the Digitalmars-d-learn mailing list