llvm-coverage-viewer

1.0.2 • Public • Published

llvm-coverage-viewer

I thought my tests covered that!

Prerequisites

  • node - any version
  • npm - any version

Prerequisites For Development

Features

  • outputs only one html file
  • syntax highlighting
  • highlights missed code coverage
  • filter files by name
  • collapsible folder tree ui
  • uses react and material-ui

Install

npm install -g llvm-coverage-viewer

Usage

After you've successfully exported your llvm coverage report as JSON, the following command will generate a beautiful report.

llvm-coverage-viewer -j json_report.json -o html_report.html

How do I export llvm code coverage to JSON?

Use the llvm-cov export command.

I created an example C++ project to generate and export llvm code coverage to JSON document for testing and development.

llvm-cov report "<executable>" -instr-profile="all.profdata"

Development

The following commands should start the development server so you can start coding. If you want to load a different llvm code coverage report while developing, you can change it by modifying the hardcoded path here

# build example c++ project 
cd test/fixtures/cpp_project
./build_report_fixture.sh
 
npm install
npm start

Readme

Keywords

none

Package Sidebar

Install

npm i llvm-coverage-viewer

Weekly Downloads

5

Version

1.0.2

License

MIT

Unpacked Size

11.1 MB

Total Files

50

Last publish

Collaborators

  • dhoodlum