tox: Drop envdir
tox now always recreates an env although the env is shared using envdir options. ~~~ $ tox -e genpolicy genpolicy: recreate env because env type changed from {'name': 'genconfig', 'type': 'VirtualEnvRunner'} to {'name': 'genpolicy', 'type': 'VirtualEnvRunner'} ~~~ According to the maintainer of tox, this functionality is not intended to be supported. https://github.com/tox-dev/tox/issues/425#issuecomment-1011944293 Change-Id: Ibda3bf5547b3530f854c667140699ecc8486ee85
This commit is contained in:
parent
179c2e3771
commit
9210f9b055
16
tox.ini
16
tox.ini
@ -31,11 +31,9 @@ commands =
|
|||||||
bash {toxinidir}/tools/unit_tests.sh {toxinidir} {posargs}
|
bash {toxinidir}/tools/unit_tests.sh {toxinidir} {posargs}
|
||||||
|
|
||||||
[testenv:venv]
|
[testenv:venv]
|
||||||
envdir = {toxworkdir}/venv
|
|
||||||
commands = {posargs}
|
commands = {posargs}
|
||||||
|
|
||||||
[testenv:pep8]
|
[testenv:pep8]
|
||||||
envdir = {toxworkdir}/linters
|
|
||||||
deps =
|
deps =
|
||||||
{[testenv]deps}
|
{[testenv]deps}
|
||||||
flake8-import-order==0.12 # LGPLv3
|
flake8-import-order==0.12 # LGPLv3
|
||||||
@ -50,7 +48,6 @@ commands =
|
|||||||
pylint -j 4 --verbose --rcfile=.pylintrc -f colorized openstack_dashboard openstack_auth horizon
|
pylint -j 4 --verbose --rcfile=.pylintrc -f colorized openstack_dashboard openstack_auth horizon
|
||||||
|
|
||||||
[testenv:cover]
|
[testenv:cover]
|
||||||
envdir = {toxworkdir}/venv
|
|
||||||
allowlist_externals =
|
allowlist_externals =
|
||||||
bash
|
bash
|
||||||
commands =
|
commands =
|
||||||
@ -61,7 +58,6 @@ commands =
|
|||||||
coverage report --show-missing --skip-covered
|
coverage report --show-missing --skip-covered
|
||||||
|
|
||||||
[testenv:selenium]
|
[testenv:selenium]
|
||||||
envdir = {toxworkdir}/venv
|
|
||||||
setenv =
|
setenv =
|
||||||
{[testenv]setenv}
|
{[testenv]setenv}
|
||||||
WITH_SELENIUM=1
|
WITH_SELENIUM=1
|
||||||
@ -70,7 +66,6 @@ commands =
|
|||||||
bash {toxinidir}/tools/selenium_tests.sh {toxinidir} {posargs}
|
bash {toxinidir}/tools/selenium_tests.sh {toxinidir} {posargs}
|
||||||
|
|
||||||
[testenv:selenium-headless]
|
[testenv:selenium-headless]
|
||||||
envdir = {toxworkdir}/venv
|
|
||||||
setenv =
|
setenv =
|
||||||
{[testenv]setenv}
|
{[testenv]setenv}
|
||||||
SELENIUM_HEADLESS=1
|
SELENIUM_HEADLESS=1
|
||||||
@ -80,7 +75,6 @@ commands =
|
|||||||
bash {toxinidir}/tools/selenium_tests.sh {toxinidir} {posargs}
|
bash {toxinidir}/tools/selenium_tests.sh {toxinidir} {posargs}
|
||||||
|
|
||||||
[testenv:selenium-phantomjs]
|
[testenv:selenium-phantomjs]
|
||||||
envdir = {toxworkdir}/venv
|
|
||||||
setenv =
|
setenv =
|
||||||
{[testenv]setenv}
|
{[testenv]setenv}
|
||||||
SELENIUM_PHANTOMJS=1
|
SELENIUM_PHANTOMJS=1
|
||||||
@ -90,7 +84,6 @@ commands =
|
|||||||
bash {toxinidir}/tools/selenium_tests.sh {toxinidir} {posargs}
|
bash {toxinidir}/tools/selenium_tests.sh {toxinidir} {posargs}
|
||||||
|
|
||||||
[testenv:integration]
|
[testenv:integration]
|
||||||
envdir = {toxworkdir}/venv
|
|
||||||
# Run integration tests only
|
# Run integration tests only
|
||||||
passenv =
|
passenv =
|
||||||
DISPLAY
|
DISPLAY
|
||||||
@ -103,7 +96,6 @@ commands =
|
|||||||
pytest --ds=openstack_dashboard.test.settings -v -x --junitxml="{toxinidir}/test_reports/integration_test_results.xml" --html="{toxinidir}/test_reports/integration_test_results.html" --self-contained-html {posargs:{toxinidir}/openstack_dashboard/test/integration_tests}
|
pytest --ds=openstack_dashboard.test.settings -v -x --junitxml="{toxinidir}/test_reports/integration_test_results.xml" --html="{toxinidir}/test_reports/integration_test_results.html" --self-contained-html {posargs:{toxinidir}/openstack_dashboard/test/integration_tests}
|
||||||
|
|
||||||
[testenv:integration-pytest]
|
[testenv:integration-pytest]
|
||||||
envdir = {toxworkdir}/venv
|
|
||||||
# Run pytest integration tests only
|
# Run pytest integration tests only
|
||||||
passenv =
|
passenv =
|
||||||
DISPLAY
|
DISPLAY
|
||||||
@ -115,7 +107,6 @@ commands =
|
|||||||
pytest -v --junitxml="{toxinidir}/test_reports/integration_pytest_results.xml" --html="{toxinidir}/test_reports/integration_pytest_results.html" --self-contained-html {posargs:{toxinidir}/openstack_dashboard/test/selenium/integration}
|
pytest -v --junitxml="{toxinidir}/test_reports/integration_pytest_results.xml" --html="{toxinidir}/test_reports/integration_pytest_results.html" --self-contained-html {posargs:{toxinidir}/openstack_dashboard/test/selenium/integration}
|
||||||
|
|
||||||
[testenv:ui-pytest]
|
[testenv:ui-pytest]
|
||||||
envdir = {toxworkdir}/venv
|
|
||||||
# Run pytest ui tests only
|
# Run pytest ui tests only
|
||||||
passenv =
|
passenv =
|
||||||
DISPLAY
|
DISPLAY
|
||||||
@ -164,7 +155,6 @@ commands =
|
|||||||
doc8 doc/source
|
doc8 doc/source
|
||||||
|
|
||||||
[testenv:pdf-docs]
|
[testenv:pdf-docs]
|
||||||
envdir = {toxworkdir}/docs
|
|
||||||
deps = {[testenv:docs]deps}
|
deps = {[testenv:docs]deps}
|
||||||
allowlist_externals =
|
allowlist_externals =
|
||||||
make
|
make
|
||||||
@ -173,35 +163,29 @@ commands =
|
|||||||
make -C doc/build/pdf
|
make -C doc/build/pdf
|
||||||
|
|
||||||
[testenv:releasenotes]
|
[testenv:releasenotes]
|
||||||
envdir = {toxworkdir}/docs
|
|
||||||
deps = {[testenv:docs]deps}
|
deps = {[testenv:docs]deps}
|
||||||
commands =
|
commands =
|
||||||
sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html
|
sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html
|
||||||
doc8 doc/source
|
doc8 doc/source
|
||||||
|
|
||||||
[testenv:manage]
|
[testenv:manage]
|
||||||
envdir = {toxworkdir}/venv
|
|
||||||
commands = {envpython} {toxinidir}/manage.py {posargs}
|
commands = {envpython} {toxinidir}/manage.py {posargs}
|
||||||
|
|
||||||
[testenv:runserver]
|
[testenv:runserver]
|
||||||
envdir = {toxworkdir}/venv
|
|
||||||
commands =
|
commands =
|
||||||
{envpython} {toxinidir}/manage.py collectstatic -v 0 -c --noinput
|
{envpython} {toxinidir}/manage.py collectstatic -v 0 -c --noinput
|
||||||
{envpython} {toxinidir}/manage.py runserver -v 0 {posargs}
|
{envpython} {toxinidir}/manage.py runserver -v 0 {posargs}
|
||||||
|
|
||||||
[testenv:translations]
|
[testenv:translations]
|
||||||
envdir = {toxworkdir}/venv
|
|
||||||
commands =
|
commands =
|
||||||
{envpython} {toxinidir}/manage.py extract_messages -v 0 --traceback
|
{envpython} {toxinidir}/manage.py extract_messages -v 0 --traceback
|
||||||
{envpython} {toxinidir}/manage.py compilemessages -v 0 --traceback
|
{envpython} {toxinidir}/manage.py compilemessages -v 0 --traceback
|
||||||
|
|
||||||
[testenv:bandit]
|
[testenv:bandit]
|
||||||
envdir = {toxworkdir}/linters
|
|
||||||
deps = {[testenv:pep8]deps}
|
deps = {[testenv:pep8]deps}
|
||||||
commands = bandit -r horizon openstack_auth openstack_dashboard -n5 -x tests -ll
|
commands = bandit -r horizon openstack_auth openstack_dashboard -n5 -x tests -ll
|
||||||
|
|
||||||
[testenv:bandit-baseline]
|
[testenv:bandit-baseline]
|
||||||
envdir = {toxworkdir}/linters
|
|
||||||
deps = {[testenv:pep8]deps}
|
deps = {[testenv:pep8]deps}
|
||||||
commands = bandit-baseline -r horizon openstack_auth openstack_dashboard -n5 -x tests -ii -ll
|
commands = bandit-baseline -r horizon openstack_auth openstack_dashboard -n5 -x tests -ii -ll
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user