Add .stestr.conf configuration
os-testr has moved over to use stestr instead of testr. While this is usually compaible with existing settings, there is a warning that is emitted when .stestr.conf is not present. It is usually able to fall back to parsing the .testr.conf file, but to be more correct and to prevent future problems we should update the config. Change-Id: I203b3bde40029e4ffc48271becfa1f7a8ce4b1f7
This commit is contained in:
parent
d56c8a72b3
commit
606525327e
2
.gitignore
vendored
2
.gitignore
vendored
@ -1,4 +1,5 @@
|
||||
*.py[cod]
|
||||
/.*
|
||||
|
||||
# C extensions
|
||||
*.so
|
||||
@ -28,6 +29,7 @@ pip-log.txt
|
||||
nosetests.xml
|
||||
.testrepository
|
||||
.venv
|
||||
cover
|
||||
|
||||
# Translations
|
||||
*.mo
|
||||
|
3
.stestr.conf
Normal file
3
.stestr.conf
Normal file
@ -0,0 +1,3 @@
|
||||
[DEFAULT]
|
||||
test_path=${OS_TEST_PATH:-./brick_cinderclient_ext/tests/unit}
|
||||
top_dir=./
|
@ -1,9 +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 ./ ${OS_TEST_PATH:-./brick_cinderclient_ext/tests/unit} \
|
||||
$LISTOPT $IDOPTION
|
||||
test_id_option=--load-list $IDFILE
|
||||
test_list_option=--list
|
@ -15,3 +15,4 @@ reno>=2.5.0 # Apache-2.0
|
||||
testrepository>=0.0.18 # Apache-2.0/BSD
|
||||
testscenarios>=0.4 # Apache-2.0/BSD
|
||||
testtools>=1.4.0 # MIT
|
||||
os-testr>=1.0.0 # Apache-2.0
|
||||
|
15
tox.ini
15
tox.ini
@ -7,13 +7,17 @@ skipsdist = True
|
||||
usedevelop = True
|
||||
install_command = pip install -c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt} {opts} {packages}
|
||||
setenv = VIRTUAL_ENV={envdir}
|
||||
OS_STDOUT_CAPTURE=1
|
||||
OS_STDERR_CAPTURE=1
|
||||
OS_TEST_TIMEOUT=60
|
||||
OS_TEST_PATH=./brick_cinderclient_ext/tests/unit
|
||||
passenv = *_proxy *_PROXY
|
||||
|
||||
deps = -r{toxinidir}/requirements.txt
|
||||
-r{toxinidir}/test-requirements.txt
|
||||
commands =
|
||||
find . -type f -name "*.pyc" -delete
|
||||
python setup.py testr --testr-args='{posargs}'
|
||||
ostestr {posargs}
|
||||
whitelist_externals = find
|
||||
|
||||
[testenv:pep8]
|
||||
@ -32,7 +36,14 @@ setenv =
|
||||
passenv = OS_*
|
||||
|
||||
[testenv:cover]
|
||||
commands = python setup.py test --coverage --testr-args='{posargs}'
|
||||
setenv =
|
||||
{[testenv]setenv}
|
||||
PYTHON=coverage run --source brick_cinderclient_ext --parallel-mode
|
||||
commands =
|
||||
stestr run {posargs}
|
||||
coverage combine
|
||||
coverage html -d cover
|
||||
coverage xml -o cover/coverage.xml
|
||||
|
||||
[testenv:docs]
|
||||
commands = python setup.py build_sphinx
|
||||
|
Loading…
Reference in New Issue
Block a user