Skip to content
Snippets Groups Projects
Commit 5e1e2853 authored by Pierre Riteau's avatar Pierre Riteau Committed by Michal Nasiadka
Browse files

Fix tox.ini for tox4

Depends-On: https://review.opendev.org/c/zuul/zuul-jobs/+/866943/

Change-Id: I66b3a85adfe2928b936006780fb20b5fc7cc802f
parent fbf00068
No related branches found
No related tags found
No related merge requests found
[tox] [tox]
minversion = 3.1 minversion = 3.1
envlist = py3,pep8 envlist = py3,pep8
skipsdist = True
ignore_basepython_conflict = True ignore_basepython_conflict = True
[testenv] [testenv]
...@@ -9,8 +8,10 @@ basepython = python3 ...@@ -9,8 +8,10 @@ basepython = python3
usedevelop = True usedevelop = True
passenv = passenv =
HOME HOME
whitelist_externals = allowlist_externals =
bash bash
make
python3
rm rm
setenv = setenv =
VIRTUAL_ENV={envdir} VIRTUAL_ENV={envdir}
...@@ -32,12 +33,12 @@ deps = ...@@ -32,12 +33,12 @@ deps =
-r{toxinidir}/doc/requirements.txt -r{toxinidir}/doc/requirements.txt
-r{toxinidir}/test-requirements.txt -r{toxinidir}/test-requirements.txt
commands = commands =
{toxinidir}/tools/run-bashate.sh bash {toxinidir}/tools/run-bashate.sh
flake8 {posargs} kayobe flake8 {posargs} kayobe
# Check the *.rst files # Check the *.rst files
# We use a thin wrapper around doc8 currently, which has support for sphinx # We use a thin wrapper around doc8 currently, which has support for sphinx
# directives. # directives.
{toxinidir}/tools/sphinx8 README.rst CONTRIBUTING.rst doc/source --ignore D001 python3 {toxinidir}/tools/sphinx8 README.rst CONTRIBUTING.rst doc/source --ignore D001
yamllint etc/kayobe yamllint etc/kayobe
[testenv:venv] [testenv:venv]
...@@ -53,21 +54,19 @@ commands = {posargs} ...@@ -53,21 +54,19 @@ commands = {posargs}
sitepackages = True sitepackages = True
commands = commands =
# Install ansible role dependencies from Galaxy. # Install ansible role dependencies from Galaxy.
{toxinidir}/tools/ansible-galaxy-retried.sh install \ bash {toxinidir}/tools/ansible-galaxy-retried.sh install \
-r {toxinidir}/requirements.yml \ -r {toxinidir}/requirements.yml \
-p {toxinidir}/ansible/roles -p {toxinidir}/ansible/roles
{toxinidir}/tools/test-ansible.sh {posargs} bash {toxinidir}/tools/test-ansible.sh {posargs}
[testenv:molecule] [testenv:molecule]
deps = deps =
-c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/zed} -c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/zed}
-r{toxinidir}/requirements.txt -r{toxinidir}/requirements.txt
-r{toxinidir}/molecule-requirements.txt -r{toxinidir}/molecule-requirements.txt
whitelist_externals =
bash
commands = commands =
# Install ansible role dependencies from Galaxy. # Install ansible role dependencies from Galaxy.
{toxinidir}/tools/ansible-galaxy-retried.sh install \ bash {toxinidir}/tools/ansible-galaxy-retried.sh install \
-r {toxinidir}/requirements.yml \ -r {toxinidir}/requirements.yml \
-p {toxinidir}/ansible/roles -p {toxinidir}/ansible/roles
bash -c "source {envdir}/bin/activate && {toxinidir}/tools/test-molecule.sh {posargs}" bash -c "source {envdir}/bin/activate && {toxinidir}/tools/test-molecule.sh {posargs}"
...@@ -78,7 +77,7 @@ commands = /bin/bash -c "ansible-lint {toxinidir}/ansible/*.yml" ...@@ -78,7 +77,7 @@ commands = /bin/bash -c "ansible-lint {toxinidir}/ansible/*.yml"
[testenv:ansible-syntax] [testenv:ansible-syntax]
commands = commands =
# Install ansible role dependencies from Galaxy. # Install ansible role dependencies from Galaxy.
{toxinidir}/tools/ansible-galaxy-retried.sh install \ bash {toxinidir}/tools/ansible-galaxy-retried.sh install \
-r {toxinidir}/requirements.yml \ -r {toxinidir}/requirements.yml \
-p {toxinidir}/ansible/roles -p {toxinidir}/ansible/roles
# Perform an Ansible syntax check. Skip some playbooks which require extra # Perform an Ansible syntax check. Skip some playbooks which require extra
...@@ -117,7 +116,6 @@ commands = ...@@ -117,7 +116,6 @@ commands =
whereto doc/source/_extra/.htaccess doc/test/redirect-tests.txt whereto doc/source/_extra/.htaccess doc/test/redirect-tests.txt
[testenv:pdf-docs] [testenv:pdf-docs]
whitelist_externals = make
deps = {[testenv:docs]deps} deps = {[testenv:docs]deps}
commands = commands =
rm -rf doc/build/pdf rm -rf doc/build/pdf
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment