Changeset e893e6fe for Makefile


Ignore:
Timestamp:
Nov 22, 2018, 6:41:41 PM (9 months ago)
Author:
Paul Brossier <piem@piem.org>
Branches:
feature/autosink, feature/constantq, feature/pitchshift, feature/timestretch, master
Children:
263dd04
Parents:
bf3f09b (diff), c4a8bc1 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge branch 'master' into feature/pytest

File:
1 edited

Legend:

Unmodified
Added
Removed
  • Makefile

    rbf3f09b re893e6fe  
    4343TESTSOUNDS := python/tests/sounds
    4444
     45LCOVOPTS += --rc lcov_branch_coverage=1
     46
    4547all: build
    4648
     
    244246coverage: force_uninstall_python deps_python \
    245247        clean_python clean distclean build local_dylib
    246         lcov --capture --no-external --directory . --output-file build/coverage_lib.info
     248        # capture coverage after running c tests
     249        lcov $(LCOVOPTS) --capture --no-external --directory . \
     250                --output-file build/coverage_lib.info
     251        # build and test python
    247252        pip install -v -e .
     253        # run tests, with python coverage
    248254        coverage run `which pytest`
    249         lcov --capture --no-external --directory . --output-file build/coverage_python.info
    250         lcov -a build/coverage_python.info -a build/coverage_lib.info -o build/coverage.info
     255        # capture coverage again
     256        lcov $(LCOVOPTS) --capture --no-external --directory . \
     257                --output-file build/coverage_python.info
     258        # merge both coverage info files
     259        lcov $(LCOVOPTS) -a build/coverage_python.info -a build/coverage_lib.info \
     260                --output-file build/coverage.info
     261        # remove tests
     262        lcov $(LCOVOPTS) --remove build/coverage.info '*/tests/*' '*/ooura_fft8g*' \
     263                --output-file build/coverage_lib.info
    251264
    252265# make sure we don't build the doc, which builds a temporary python module
    253266coverage_report: export WAFOPTS += --disable-docs
    254267coverage_report: coverage
    255         genhtml build/coverage.info --output-directory lcov_html
    256         mkdir -p gcovr_html/
    257         gcovr -r . --html --html-details \
    258                 --output gcovr_html/index.html \
    259                 --exclude ".*tests/.*" --exclude ".*examples/.*"
     268        # create coverage report dir
     269        mkdir -p build/coverage/
     270        # generate report with lcov's genhtml
     271        genhtml build/coverage_lib.info --output-directory build/coverage/lcov \
     272                --branch-coverage --highlight --legend
     273        # generate python report with coverage python package
    260274        coverage report
    261         coverage html
     275        coverage html -d build/coverage/coverage
     276        # show links to generated reports
     277        for i in $$(ls build/coverage/*/index.html); do echo file://$(PWD)/$$i; done
    262278
    263279sphinx: configure
Note: See TracChangeset for help on using the changeset viewer.