Add tox targets for functional testing on 2 and 3
Previously, the functional tests would run using the `python` in your environment, which was 3 for myself and 2 for most others. We should really be testing on both versions as we do for unit tests. A change to the gate will follow this. Change-Id: I2bd2664018c135593a96fd6ba5741279da772e76 Closes-Bug: 1489935
This commit is contained in:
@@ -82,15 +82,19 @@ Replace ``xxx.xxx.xxx.xxx`` with the IP address or FQDN of your DevStack instanc
|
||||
Run
|
||||
***
|
||||
|
||||
In order to run the entire functional test suite, simply run the
|
||||
``tox -e functional`` command inside of your source checkout. This will
|
||||
Functional tests are run against both Python 2 and 3. In order to run the
|
||||
entire functional test suite, run the ``tox -e functional`` and
|
||||
``tox -e functional3`` command inside of your source checkout. This will
|
||||
attempt to run every test command under ``/openstack/tests/functional/``
|
||||
in the source tree. The functional tests are run with your system Python
|
||||
interpreter. You should run the full functional test suite before submitting
|
||||
changes for review in order to avoid unexpected failures in the continuous
|
||||
integration system.::
|
||||
in the source tree. You should run the full functional test suite before
|
||||
submitting changes for review in order to avoid unexpected failures in
|
||||
the continuous integration system.::
|
||||
|
||||
(sdk3)$ tox -e functional
|
||||
...
|
||||
functional: commands succeeded
|
||||
congratulations :)
|
||||
(sdk3)$ tox -e functional3
|
||||
...
|
||||
functional3: commands succeeded
|
||||
congratulations :)
|
||||
|
12
tox.ini
12
tox.ini
@@ -11,10 +11,20 @@ setenv =
|
||||
deps = -r{toxinidir}/test-requirements.txt
|
||||
commands = ostestr {posargs}
|
||||
|
||||
[testenv:functional]
|
||||
[functionalbase]
|
||||
setenv = OS_TEST_PATH=./openstack/tests/functional
|
||||
passenv = OS_*
|
||||
|
||||
[testenv:functional]
|
||||
basepython = python2.7
|
||||
setenv = {[functionalbase]setenv}
|
||||
passenv = {[functionalbase]passenv}
|
||||
|
||||
[testenv:functional3]
|
||||
basepython = python3.4
|
||||
setenv = {[functionalbase]setenv}
|
||||
passenv = {[functionalbase]passenv}
|
||||
|
||||
[testenv:pep8]
|
||||
commands = flake8
|
||||
|
||||
|
Reference in New Issue
Block a user