Fix coverage testing settings
This fixes some config issues so that coverage tests can be run properly. Change-Id: Iaac0de8532f334fc1950e80e996733857f322c37
This commit is contained in:
parent
445b4ace80
commit
b23f88bae4
|
@ -1,7 +1,7 @@
|
||||||
[run]
|
[run]
|
||||||
branch = True
|
branch = True
|
||||||
source = nova_solverscheduler
|
source = nova_solverscheduler
|
||||||
omit = nova_solverscheduler/openstack/*
|
omit = nova_solverscheduler/tests/*
|
||||||
|
|
||||||
[report]
|
[report]
|
||||||
ignore-errors = True
|
ignore-errors = True
|
||||||
|
|
|
@ -2,6 +2,6 @@
|
||||||
test_command=OS_STDOUT_CAPTURE=${OS_STDOUT_CAPTURE:-1} \
|
test_command=OS_STDOUT_CAPTURE=${OS_STDOUT_CAPTURE:-1} \
|
||||||
OS_STDERR_CAPTURE=${OS_STDERR_CAPTURE:-1} \
|
OS_STDERR_CAPTURE=${OS_STDERR_CAPTURE:-1} \
|
||||||
OS_TEST_TIMEOUT=${OS_TEST_TIMEOUT:-60} \
|
OS_TEST_TIMEOUT=${OS_TEST_TIMEOUT:-60} \
|
||||||
${PYTHON:-python} -m subunit.run discover -t ./ . $LISTOPT $IDOPTION
|
${PYTHON:-python} -m subunit.run discover -t ./ ${OS_TEST_PATH:-./nova_solverscheduler/tests} $LISTOPT $IDOPTION
|
||||||
test_id_option=--load-list $IDFILE
|
test_id_option=--load-list $IDFILE
|
||||||
test_list_option=--list
|
test_list_option=--list
|
||||||
|
|
8
tox.ini
8
tox.ini
|
@ -19,7 +19,13 @@ commands = flake8
|
||||||
commands = {posargs}
|
commands = {posargs}
|
||||||
|
|
||||||
[testenv:cover]
|
[testenv:cover]
|
||||||
commands = python setup.py test --coverage --testr-args='{posargs}'
|
whitelist_externals = ln
|
||||||
|
commands =
|
||||||
|
# pbr assumes that the coverage source is nova-solver-scheduler
|
||||||
|
# we want it to be nova_solverscheduler
|
||||||
|
ln -sf nova_solverscheduler nova-solver-scheduler
|
||||||
|
python setup.py test --coverage --testr-args='{posargs}'
|
||||||
|
coverage report
|
||||||
|
|
||||||
[testenv:docs]
|
[testenv:docs]
|
||||||
commands = python setup.py build_sphinx
|
commands = python setup.py build_sphinx
|
||||||
|
|
Loading…
Reference in New Issue