Replace nose with testr
- add .testr.conf (in base dir and nova_tests) - remove all references to nose - adjust paths: A couple of tests would assume the current directory was ./tests/ but it is now ./ - don't run the tests in parallel as the db tests have one connection per test class. nova_tests hackery: It seems testtools/testr imports everything and I just don't see a way of running things in tests/ and nova_tests/ seperately but in one .test.conf. So if you want to use testr directly you will need to: testr run cd nova_tests testr run part of bug 1177924 Change-Id: I41875dcf94463fa5f9c07a7840c37089226c59ad
This commit is contained in:
14
tox.ini
14
tox.ini
@@ -5,18 +5,16 @@ envlist = py26,py27,pep8
|
||||
deps = -r{toxinidir}/tools/test-requires
|
||||
-r{toxinidir}/tools/pip-requires
|
||||
setenv = VIRTUAL_ENV={envdir}
|
||||
NOSE_WITH_OPENSTACK=1
|
||||
NOSE_OPENSTACK_COLOR=1
|
||||
NOSE_OPENSTACK_RED=0.05
|
||||
NOSE_OPENSTACK_YELLOW=0.025
|
||||
NOSE_OPENSTACK_SHOW_ELAPSED=1
|
||||
EVENTLET_NO_GREENDNS=yes
|
||||
commands =
|
||||
nosetests --no-path-adjustment --where=../nova_tests
|
||||
nosetests --no-path-adjustment {posargs}
|
||||
python setup.py testr --slowest --testr-args='--concurrency=1 {posargs}'
|
||||
bash tools/init_testr_if_needed.sh
|
||||
python setup.py testr --slowest --testr-args='--concurrency=1 --here=nova_tests {posargs}'
|
||||
sitepackages = False
|
||||
|
||||
[testenv:cover]
|
||||
commands = nosetests --no-path-adjustment --with-coverage --cover-erase --cover-package=ceilometer --cover-inclusive []
|
||||
setenv = VIRTUAL_ENV={envdir}
|
||||
commands = python setup.py testr --coverage
|
||||
|
||||
[testenv:pep8]
|
||||
# Install bounded pep8/pyflakes first, then let flake8 install
|
||||
|
||||
Reference in New Issue
Block a user