Migrate from testr to stestr
Change-Id: I735638f91617d2e951c3ec23498c8ac116cf8f08
This commit is contained in:
parent
9ea447c296
commit
6c611a3c61
|
@ -3,4 +3,5 @@
|
||||||
.stestr
|
.stestr
|
||||||
.unit-state.db
|
.unit-state.db
|
||||||
**/__pycache__/
|
**/__pycache__/
|
||||||
|
.coverage
|
||||||
|
cover/
|
||||||
|
|
|
@ -0,0 +1,3 @@
|
||||||
|
[DEFAULT]
|
||||||
|
test_path=./unit_tests
|
||||||
|
top_dir=./
|
|
@ -1,8 +0,0 @@
|
||||||
[DEFAULT]
|
|
||||||
test_command=OS_STDOUT_CAPTURE=${OS_STDOUT_CAPTURE:-1} \
|
|
||||||
OS_STDERR_CAPTURE=${OS_STDERR_CAPTURE:-1} \
|
|
||||||
OS_TEST_TIMEOUT=${OS_TEST_TIMEOUT:-60} \
|
|
||||||
${PYTHON:-python} -m subunit.run discover -t ./ ./unit_tests $LISTOPT $IDOPTION
|
|
||||||
|
|
||||||
test_id_option=--load-list $IDFILE
|
|
||||||
test_list_option=--list
|
|
|
@ -1,6 +1,6 @@
|
||||||
# Lint and unit test requirements
|
# Lint and unit test requirements
|
||||||
flake8
|
flake8
|
||||||
os-testr>=0.4.1
|
stestr>=2.2.0
|
||||||
charms.reactive
|
charms.reactive
|
||||||
coverage>=3.6
|
coverage>=3.6
|
||||||
netifaces
|
netifaces
|
||||||
|
|
17
tox.ini
17
tox.ini
|
@ -11,27 +11,32 @@ setenv = VIRTUAL_ENV={envdir}
|
||||||
PYTHONHASHSEED=0
|
PYTHONHASHSEED=0
|
||||||
install_command =
|
install_command =
|
||||||
pip install {opts} {packages}
|
pip install {opts} {packages}
|
||||||
commands = ostestr {posargs}
|
commands = stestr run {posargs}
|
||||||
|
|
||||||
[testenv:py34]
|
[testenv:py34]
|
||||||
basepython = python3.4
|
basepython = python3.4
|
||||||
deps = -r{toxinidir}/test-requirements.txt
|
deps = -r{toxinidir}/test-requirements.txt
|
||||||
commands = ostestr {posargs}
|
commands = stestr run {posargs}
|
||||||
|
|
||||||
[testenv:py35]
|
[testenv:py35]
|
||||||
basepython = python3.5
|
basepython = python3.5
|
||||||
deps = -r{toxinidir}/test-requirements.txt
|
deps = -r{toxinidir}/test-requirements.txt
|
||||||
commands = ostestr {posargs}
|
commands = stestr run {posargs}
|
||||||
|
|
||||||
[testenv:py36]
|
[testenv:py36]
|
||||||
basepython = python3.6
|
basepython = python3.6
|
||||||
deps = -r{toxinidir}/test-requirements.txt
|
deps = -r{toxinidir}/test-requirements.txt
|
||||||
commands = ostestr {posargs}
|
commands = stestr run {posargs}
|
||||||
|
|
||||||
[testenv:py37]
|
[testenv:py37]
|
||||||
basepython = python3.7
|
basepython = python3.7
|
||||||
deps = -r{toxinidir}/test-requirements.txt
|
deps = -r{toxinidir}/test-requirements.txt
|
||||||
commands = ostestr {posargs}
|
commands = stestr run {posargs}
|
||||||
|
|
||||||
|
[testenv:py3]
|
||||||
|
basepython = python3
|
||||||
|
deps = -r{toxinidir}/test-requirements.txt
|
||||||
|
commands = stestr run {posargs}
|
||||||
|
|
||||||
[testenv:pep8]
|
[testenv:pep8]
|
||||||
basepython = python3
|
basepython = python3
|
||||||
|
@ -48,7 +53,7 @@ setenv =
|
||||||
PYTHON=coverage run
|
PYTHON=coverage run
|
||||||
commands =
|
commands =
|
||||||
coverage erase
|
coverage erase
|
||||||
ostestr {posargs}
|
stestr run {posargs}
|
||||||
coverage combine
|
coverage combine
|
||||||
coverage html -d cover
|
coverage html -d cover
|
||||||
coverage xml -o cover/coverage.xml
|
coverage xml -o cover/coverage.xml
|
||||||
|
|
Loading…
Reference in New Issue