Skip to content

Commit

Permalink
Switch to stestr
Browse files Browse the repository at this point in the history
According to Openstack summit session [1] stestr is
maintained project to which all Openstack projects
should migrate.
Let's switch it then.

[1] https://etherpad.openstack.org/p/YVR-python-pti

Change-Id: I9fd237292f7da50e60da398b1649001bf1829c66
  • Loading branch information
slawqo committed Jun 7, 2018
1 parent 26bfa08 commit 93a8b15
Show file tree
Hide file tree
Showing 6 changed files with 18 additions and 27 deletions.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ subunit.log
!/.mailmap
!/.pylintrc
!/.stestr.conf
!/.testr.conf
!/.zuul.yaml

# Files created by releasenotes build
Expand Down
10 changes: 0 additions & 10 deletions .testr.conf

This file was deleted.

1 change: 0 additions & 1 deletion lower-constraints.txt
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,6 @@ openstackdocstheme==1.18.1
openstacksdk==0.11.2
os-client-config==1.28.0
os-service-types==1.2.0
os-testr==1.0.0
os-xenapi==0.3.1
osc-lib==1.8.0
oslo.cache==1.26.0
Expand Down
2 changes: 1 addition & 1 deletion test-requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ python-subunit>=1.0.0 # Apache-2.0/BSD
sphinx!=1.6.6,!=1.6.7,>=1.6.5 # BSD
openstackdocstheme>=1.18.1 # Apache-2.0
oslo.concurrency>=3.25.0 # Apache-2.0
os-testr>=1.0.0 # Apache-2.0
stestr>=1.0.0 # Apache-2.0
testresources>=2.0.0 # Apache-2.0/BSD
testtools>=2.2.0 # MIT
testscenarios>=0.4 # Apache-2.0/BSD
Expand Down
8 changes: 0 additions & 8 deletions tools/ostestr_compat_shim.sh

This file was deleted.

23 changes: 17 additions & 6 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ skipsdist = True

[testenv]
setenv = VIRTUAL_ENV={envdir}
OS_LOG_CAPTURE={env:OS_LOG_CAPTURE:true}
OS_STDOUT_CAPTURE={env:OS_STDOUT_CAPTURE:true}
OS_STDERR_CAPTURE={env:OS_STDERR_CAPTURE:true}
PYTHONWARNINGS=default::DeprecationWarning
usedevelop = True
install_command =pip install {opts} {packages}
Expand All @@ -17,14 +20,15 @@ whitelist_externals =
commands =
find . -type f -name "*.py[c|o]" -delete
find . -type d -name "__pycache__" -delete
ostestr '{posargs}'
# there is also secret magic in ostestr which lets you run in a fail only
stestr run {posargs}
# there is also secret magic in stestr which lets you run in a fail only
# mode. To do this define the TRACE_FAILONLY environmental variable.

[testenv:functional]
setenv = OS_TEST_PATH=./neutron_dynamic_routing/tests/functional
commands =
ostestr --slowest '{posargs}'
stestr run {posargs}
stestr slowest

[testenv:api]
sitepackages=True
Expand All @@ -33,7 +37,8 @@ setenv =
OS_TESTR_CONCURRENCY=1
TEMPEST_CONFIG_DIR={env:TEMPEST_CONFIG_DIR:/opt/stack/tempest/etc}
commands =
ostestr --slowest '{posargs}'
stestr run {posargs}
stestr slowest

[testenv:dsvm-functional]
setenv =
Expand All @@ -47,7 +52,7 @@ whitelist_externals =
cp
sudo
commands =
ostestr '{posargs}'
stestr run {posargs}

[testenv:releasenotes]
commands = sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html
Expand All @@ -59,8 +64,14 @@ commands =
{[testenv:genconfig]commands}

[testenv:cover]
setenv =
{[testenv]setenv}
PYTHON=coverage run --source neutron_dynamic_routing --parallel-mode
commands =
python setup.py test --coverage --coverage-package-name=neutron_dynamic_routing --testr-args='{posargs}'
stestr run --no-subunit-trace {posargs}
coverage combine
coverage html -d cover
coverage xml -o cover/coverage.xml

[testenv:venv]
commands = {posargs}
Expand Down

0 comments on commit 93a8b15

Please sign in to comment.