Allow running individual tests via tox
Allow passing a test module name via the tox command line to allow running individual tests. Change-Id: Iff551d054e2a8252f437f6756760cd4418abcfa4
This commit is contained in:
parent
a764dafb58
commit
517ea8eccb
|
@ -509,7 +509,7 @@ class OpenStackAuthTestsV3(OpenStackAuthTestsMixin, test.TestCase):
|
|||
def setUp(self):
|
||||
super(OpenStackAuthTestsV3, self).setUp()
|
||||
|
||||
if self.interface:
|
||||
if getattr(self, 'interface', None):
|
||||
override = self.settings(OPENSTACK_ENDPOINT_TYPE=self.interface)
|
||||
override.enable()
|
||||
self.addCleanup(override.disable)
|
||||
|
|
6
tox.ini
6
tox.ini
|
@ -14,15 +14,15 @@ setenv = VIRTUAL_ENV={envdir}
|
|||
NOSE_OPENSTACK_SHOW_ELAPSED=1
|
||||
deps = -r{toxinidir}/requirements.txt
|
||||
-r{toxinidir}/test-requirements.txt
|
||||
commands = python openstack_auth/tests/run_tests.py
|
||||
commands = python openstack_auth/tests/run_tests.py {posargs}
|
||||
|
||||
[testenv:py27dj15]
|
||||
commands = pip install django>=1.5,<1.6
|
||||
python openstack_auth/tests/run_tests.py
|
||||
python openstack_auth/tests/run_tests.py {posargs}
|
||||
|
||||
[testenv:py27dj14]
|
||||
commands = pip install django>=1.4,<1.5
|
||||
python openstack_auth/tests/run_tests.py
|
||||
python openstack_auth/tests/run_tests.py {posargs}
|
||||
|
||||
[testenv:pep8]
|
||||
setenv = DJANGO_SETTINGS_MODULE=openstack_auth.tests.settings
|
||||
|
|
Loading…
Reference in New Issue