Merge "tox: Bump minimum to v4"

This commit is contained in:
Zuul 2025-04-15 12:39:34 +00:00 committed by Gerrit Code Review
commit 97c63dbb40

76
tox.ini
View File

@ -1,34 +1,29 @@
[tox]
minversion = 3.18.0
minversion = 4.6
envlist = py3,pep8
skipsdist = True
# this allows tox to infer the base python from the environment name
# and override any basepython configured in this file
ignore_basepython_conflict=true
[testenv]
basepython = python3
usedevelop = True
install_command = pip install {opts} {packages}
setenv = VIRTUAL_ENV={envdir}
ZAQAR_TESTS_CONFIGS_DIR={toxinidir}/zaqar/tests/etc/
ZAQAR_TEST_MONGODB=1
ZAQAR_TEST_SLOW=1
OS_STDOUT_CAPTURE=1
OS_STDERR_CAPTURE=1
OS_TEST_TIMEOUT=60
usedevelop = true
setenv =
VIRTUAL_ENV={envdir}
ZAQAR_TESTS_CONFIGS_DIR={toxinidir}/zaqar/tests/etc/
ZAQAR_TEST_MONGODB=1
ZAQAR_TEST_SLOW=1
OS_STDOUT_CAPTURE=1
OS_STDERR_CAPTURE=1
OS_TEST_TIMEOUT=60
deps =
-c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/test-requirements.txt
-r{toxinidir}/requirements.txt
commands =
stestr run --serial --slowest {posargs}
stestr run --serial --slowest {posargs}
[testenv:integration]
setenv = {[testenv]setenv}
ZAQAR_TEST_INTEGRATION=1
OS_TEST_PATH=./zaqar/tests/functional
commands = stestr run --serial --slowest {posargs}
setenv =
{[testenv]setenv}
ZAQAR_TEST_INTEGRATION=1
OS_TEST_PATH=./zaqar/tests/functional
[testenv:pep8]
commands =
@ -45,48 +40,49 @@ commands =
[testenv:cover]
setenv =
{[testenv]setenv}
PYTHON=coverage run --source zaqar --parallel-mode
{[testenv]setenv}
PYTHON=coverage run --source zaqar --parallel-mode
commands =
{[testenv]commands}
coverage combine
coverage html -d cover
coverage xml -o cover/coverage.xml
{[testenv]commands}
coverage combine
coverage html -d cover
coverage xml -o cover/coverage.xml
[testenv:venv]
commands = {posargs}
[testenv:docs]
deps =
-c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/requirements.txt
-r{toxinidir}/doc/requirements.txt
-c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/requirements.txt
-r{toxinidir}/doc/requirements.txt
commands =
sphinx-build -W -b html doc/source doc/build/html
sphinx-build -W -b html doc/source doc/build/html
[testenv:api-ref]
# This environment is called from CI scripts to test and publish
# the API Ref to docs.openstack.org.
#
allowlist_externals = bash
rm
allowlist_externals =
bash
rm
deps =
-c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/doc/requirements.txt
-c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/doc/requirements.txt
commands =
rm -rf api-ref/build
sphinx-build -W -b html -d api-ref/build/doctrees api-ref/source api-ref/build/html
rm -rf api-ref/build
sphinx-build -W -b html -d api-ref/build/doctrees api-ref/source api-ref/build/html
[testenv:debug]
commands = oslo_debug_helper {posargs}
[testenv:releasenotes]
deps =
-c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/doc/requirements.txt
-c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/doc/requirements.txt
commands =
doc8 releasenotes/source releasenotes/notes
sphinx-build -a -E -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html
doc8 releasenotes/source releasenotes/notes
sphinx-build -a -E -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html
[flake8]
exclude = .venv*,.git,.tox,dist,doc,*lib/python*,*.egg,.update-venv