From 7be8df222debae9eaa8e357571e75f8ee226ff40 Mon Sep 17 00:00:00 2001 From: Tobi-wan Kenobi Date: Sat, 4 Mar 2017 11:35:25 +0100 Subject: [PATCH] [runtests] Clean up coverage report + add it to runtests.sh runtests.sh now also reports coverage. --- .coveragerc | 9 +++++++++ runtests.sh | 4 ++-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/.coveragerc b/.coveragerc index f593bd0..d98e676 100644 --- a/.coveragerc +++ b/.coveragerc @@ -1,3 +1,12 @@ [run] omit = tests/* + *mock* + *funcsigs* + *pbr* + *six* + +[report] + exclude_lines = + except ImportError: + pass diff --git a/runtests.sh b/runtests.sh index a267458..60f058e 100755 --- a/runtests.sh +++ b/runtests.sh @@ -1,11 +1,11 @@ #!/bin/sh echo "testing with $(python2 -V 2>&1)" -python2 $(which nosetests) --rednose -v tests/ +python2 $(which nosetests) --rednose -v --with-coverage --cover-erase tests/ if [ $? == 0 ]; then echo echo "testing with $(python3 -V 2>&1)" - python3 $(which nosetests-3) --rednose -v tests/ + python3 $(which nosetests-3) --rednose -v --with-coverage --cover-erase tests/ fi