Skip to content

Instantly share code, notes, and snippets.

@adiog
Created October 27, 2017 17:07
Show Gist options
  • Save adiog/b967e45a33d17e84e50cb03e04c1b592 to your computer and use it in GitHub Desktop.
Save adiog/b967e45a33d17e84e50cb03e04c1b592 to your computer and use it in GitHub Desktop.
coverage.sh
#!/usr/bash
lcov --directory . --zerocounters
ctest
lcov --directory . --capture --output-file test-coverage.info
lcov --remove test-coverage.info 'test/include/*' 'test/src/*' '/usr/*' --output-file test-coverage.info
genhtml --output-directory test-coverage test-coverage.info
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment