Skip to content

Minimal, reproducible example for testing code coverage using GCC or Clang

Notifications You must be signed in to change notification settings

uncomputable/coverage-example

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Example for testing code coverage [GCC, Clang]

A minimal, reproducible example for testing code coverage of C code using GCC or Clang.

Set up GCC

Use nix for an automatic setup.

nix develop

Otherwise, install gcc, just and lcov.

Test coverage using GCC

Run the report target to generate an HTML coverage report.

just report

Take a look at the justfile to see the individual steps.

Set up Clang

Use nix for an automatic setup.

nix develop .#clang

Otherwise, install clang, just, lcov and llvm.

Test coverage using Clang

Run the report1 target to generate an HTML coverage report.

just report1

Take a look at the justfile to see the individual steps.

About

Minimal, reproducible example for testing code coverage using GCC or Clang

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published