Move unit tests execution to stestr
From time to time, unit tests execution fails with error: "TypeError: 'NoneType' object is not iterable". It seems that problem is in unittest2 library, which is used by testtools for executing the tests. Stestr lib is usinig unittest by default and the problem does not appear for several hundred launches. Authored-By: danpawlik <dpawlik@redhat.com> Change-Id: I6646629128d9265b5fb7390dc131c55cf34a07ca Signed-off-by: Gael Chamoulaud (Strider) <gchamoul@redhat.com>
This commit is contained in:
parent
8b014a6d4a
commit
3cc5263983
1
.gitignore
vendored
1
.gitignore
vendored
@ -29,6 +29,7 @@ cover/
|
||||
nosetests.xml
|
||||
.testrepository
|
||||
.venv
|
||||
.stestr/
|
||||
|
||||
# Translations
|
||||
*.mo
|
||||
|
3
.stestr.conf
Normal file
3
.stestr.conf
Normal file
@ -0,0 +1,3 @@
|
||||
[DEFAULT]
|
||||
test_path=./validations_libs/tests
|
||||
top_dir=./
|
@ -1,7 +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 ./ . $LISTOPT $IDOPTION
|
||||
test_id_option=--load-list $IDFILE
|
||||
test_list_option=--list
|
@ -104,6 +104,7 @@ smmap2==2.0.3
|
||||
snowballstemmer==1.2.1
|
||||
Sphinx==1.8.0
|
||||
sphinxcontrib-websupport==1.0.1
|
||||
stestr==1.0.0
|
||||
stevedore==1.28.0
|
||||
tenacity==5.0.1
|
||||
testrepository==0.0.18
|
||||
|
@ -9,7 +9,7 @@ coverage!=4.4,>=4.0 # Apache-2.0
|
||||
python-subunit>=1.0.0 # Apache-2.0/BSD
|
||||
sphinx>=1.8.0,<2.0.0;python_version=='2.7' # BSD
|
||||
sphinx>=1.8.0,!=2.1.0;python_version>='3.4' # BSD
|
||||
testrepository>=0.0.18 # Apache-2.0/BSD
|
||||
stestr>=1.0.0 # Apache-2.0
|
||||
testscenarios>=0.4 # Apache-2.0/BSD
|
||||
testtools>=2.2.0 # MIT
|
||||
pre-commit # MIT
|
||||
|
4
tox.ini
4
tox.ini
@ -11,7 +11,9 @@ setenv =
|
||||
# paramiko CryptographyDeprecationWarning: https://github.com/ansible/ansible/issues/52598
|
||||
PYTHONWARNINGS=ignore:DEPRECATION::pip._internal.cli.base_command,ignore::UserWarning
|
||||
PIP_DISABLE_PIP_VERSION_CHECK=1
|
||||
commands = python setup.py test --slowest --testr-args='{posargs}'
|
||||
commands =
|
||||
stestr run {posargs}
|
||||
stestr slowest
|
||||
sitepackages = True
|
||||
deps =
|
||||
-c {env:UPPER_CONSTRAINTS_FILE:https://opendev.org/openstack/requirements/raw/branch/master/upper-constraints.txt}
|
||||
|
Loading…
x
Reference in New Issue
Block a user