Skip to content

Commit

Permalink
[#407] Add make coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
Donnie-Ice committed Dec 6, 2024
1 parent b8a8a16 commit b188665
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
5 changes: 1 addition & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,10 +58,7 @@ jobs:
- name: sample
run: make coverage-sample
- name: Generate Coverage Report
run: |
lcov --capture --directory . --output-file coverage.info
lcov --remove coverage.info '/usr/*' --output-file coverage.info
genhtml coverage.info --output-directory coverage
run: make coverage
- name: Upload Coverage Report as Artifact
uses: actions/upload-artifact@v3
with:
Expand Down
5 changes: 5 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,11 @@ config:
coverage-sample:
cd $(FSWBUILDDIR)/amd64-posix/default_cpu1 && ctest -R ".*sample.*"

coverage:
lcov --capture --directory $(FSWBUILDDIR)/amd64-posix/default_cpu1 --output-file coverage.info
lcov --remove coverage.info '/usr/*' --output-file coverage.info
genhtml coverage.info --output-directory coverage

debug:
./scripts/debug.sh

Expand Down

0 comments on commit b188665

Please sign in to comment.