Fix coverage target

Previously the coverage target ended up deleting the coverage data when
the `coverage combine` command ran. This then caused the `coverage html`
command to fail due to lack of data to report on.

Thankfully the fix is simple because pbr is actually handlign all of
this for us behind the scenes. All we need to do is run with the
--coverage flag and make sure the .coveragerc reflects the desired
inclusions and ommisions.

Change-Id: Ide6c7639a19d961e4af27c2c59b036395e2af3ef
This commit is contained in:
Clark Boylan 2016-07-27 14:11:06 -07:00
parent 65bdaea32a
commit 98c4f4dbea
2 changed files with 3 additions and 2 deletions

3
.coveragerc Normal file
View File

@ -0,0 +1,3 @@
[report]
include = ironicclient/*
omit = ironicclient/tests/functional/*

View File

@ -30,8 +30,6 @@ setenv = VIRTUAL_ENV={envdir}
commands = commands =
coverage erase coverage erase
python setup.py testr --coverage --testr-args='{posargs}' python setup.py testr --coverage --testr-args='{posargs}'
coverage combine
coverage html --include='ironicclient/*' --omit='ironicclient/tests/functional/*' -d covhtml -i
[testenv:venv] [testenv:venv]
commands = {posargs} commands = {posargs}