Skip to content

Commit

Permalink
Added coverage targets to Makefile.am for convenience. (#2039)
Browse files Browse the repository at this point in the history
Signed-off-by: Toni Uhlig <[email protected]>
  • Loading branch information
utoni authored Jul 7, 2023
1 parent bdd295b commit 72814be
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 5 deletions.
4 changes: 1 addition & 3 deletions .github/workflows/build_scheduled.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,7 @@ jobs:
make check VERBOSE=1
- name: Generate Coverage Report
run: |
mkdir -vp coverage_report/ndpi_coverage_report
lcov --directory . --capture --output-file lcov.info
genhtml -o coverage_report/ndpi_coverage_report lcov.info
make coverage
- uses: actions/upload-artifact@v3
with:
name: ndpi-coverage-report
Expand Down
14 changes: 12 additions & 2 deletions Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,23 @@ EXTRA_DIST = README.md README.fuzzer.md CHANGELOG.md CONTRIBUTING.md \
python/requirements.txt python/setup.py python/tests.py \
sonar-project.properties .github .ci-ignore


.PHONY: doc doc-view
doc:
make -C doc html

doc-view:
python3 -m http.server --bind 127.0.0.1 --directory doc/_build/html 8080

coverage: all
mkdir -vp coverage_report/ndpi_coverage_report
lcov --directory . --capture --output-file lcov.info
genhtml -o coverage_report/ndpi_coverage_report lcov.info

clean-coverage:
rm -f lcov.info
find . -type f -name "*.gcda" -exec rm "{}" +
find . -type f -name "*.gcno" -exec rm "{}" +

changelog:
git log --since={`curl -s https://github.com/ntop/ndpi/releases | grep datetime | head -n1 | egrep -o "[0-9]+\-[0-9]+\-[0-9]+"`} --name-only --pretty=format:" - %s" | grep "^ " > CHANGELOG.latest

.PHONY: doc doc-view coverage clean-coverage changelog

0 comments on commit 72814be

Please sign in to comment.