Skip to content

Commit

Permalink
coverage: Added coverage makefile target
Browse files Browse the repository at this point in the history
Added coverage files to `clean` and `coverage` target to generate HTML
report of coverage.
  • Loading branch information
cdecker authored and rustyrussell committed Jan 9, 2017
1 parent bd6b9c3 commit 07fbeee
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,4 @@ libsecp256k1.la
gen_*
daemon/lightning-cli
check-bolt
coverage
9 changes: 9 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -271,6 +271,13 @@ check-source: check-makefile check-source-bolt check-whitespace \

full-check: check $(TEST_PROGRAMS) check-source

coverage/coverage.info: check $(TEST_PROGRAMS)
mkdir coverage || true
lcov --capture --directory . --output-file coverage/coverage.info

coverage: coverage/coverage.info
genhtml coverage/coverage.info --output-directory coverage

# Ignore test/ directories.
TAGS: FORCE
$(RM) TAGS; find * -name test -type d -prune -o -name '*.[ch]' -print | xargs etags --append
Expand Down Expand Up @@ -360,6 +367,8 @@ clean: daemon-clean wire-clean
$(RM) ccan/config.h gen_*.h
$(RM) ccan/ccan/cdump/tools/cdump-enumstr.o
$(RM) doc/deployable-lightning.{aux,bbl,blg,dvi,log,out,tex}
find . -name '*gcda' -delete
find . -name '*gcno' -delete

include daemon/Makefile

Expand Down

0 comments on commit 07fbeee

Please sign in to comment.