Fix coverage test
File .testr.conf was removed in patch [1]. It will make the coverage ci job failed (and tox -ecover also). This patch will change cover command in tox.ini to fix coverage test without bring .testr.conf back. [1] https://review.openstack.org/#/c/504342/ Change-Id: Id9635a42255272396c1a5f45105360325fc74d2e Closes-Bug: #1719083
This commit is contained in:
parent
f34d0a017f
commit
0a4fefc3ff
|
@ -1,4 +0,0 @@
|
|||
[DEFAULT]
|
||||
test_command=OS_STDOUT_CAPTURE=1 OS_STDERR_CAPTURE=1 OS_LOG_CAPTURE=1 ${PYTHON:-python} -m subunit.run discover -t ./ ${OS_TEST_PATH:-./kuryr_libnetwork/tests/unit} $LISTOPT $IDOPTION | cat
|
||||
test_id_option=--load-list $IDFILE
|
||||
test_list_option=--list
|
11
tox.ini
11
tox.ini
|
@ -42,10 +42,15 @@ commands = flake8
|
|||
commands = {posargs}
|
||||
|
||||
[testenv:cover]
|
||||
setenv =
|
||||
VIRTUAL_ENV={envdir}
|
||||
PYTHON=coverage run --source kuryr_libnetwork --parallel-mode
|
||||
commands =
|
||||
python setup.py test --coverage --testr-args='{posargs}' \
|
||||
--coverage-package-name=kuryr_libnetwork
|
||||
coverage report
|
||||
stestr run {posargs}
|
||||
coverage combine
|
||||
coverage html -d cover
|
||||
coverage xml -o cover/coverage.xml
|
||||
coverage report
|
||||
|
||||
[testenv:docs]
|
||||
commands = python setup.py build_sphinx
|
||||
|
|
Loading…
Reference in New Issue