5f96957c83
py37 test started to fail with latest virtualenv (20.16.4) as it
bundles setuptools 65.3.0, which causes installation problems under
py37. (Note: with py38 the problem does not occur).
This patch sets virtualenv<20.16.4 to unblock the gate as
virtualenv 20.16.3 bundles setuptools 63.4.1, with which py37 gate
works well.
NOTE(stephenfin): Modified to remove the (failing) l-c job.
Conflicts:
.zuul.yaml
tox.ini
NOTE(elod.illes): conflict in .zuul.yaml is caused by ussuri job
template changes; conflict in tox.ini is caused by tox.ini cleanup
in ussuri: Ic951cc21208e54105cfd42fbd28ce1f2f738cced
Change-Id: I4900569923796db2391d146f063cbabadb60e686
(cherry picked from commit 4f1f1cd8c2
)
81 lines
1.9 KiB
INI
81 lines
1.9 KiB
INI
[tox]
|
||
minversion = 2.0
|
||
envlist = py27,py37,pypy,pep8
|
||
# Pin setuptools via virtualenv as latest virtualenv pulls in 65.3.0
|
||
# version of setuptools for py37, which causes installation problems
|
||
# (virtualenv 20.16.3 uses setuptools 63.4.1).
|
||
requires = virtualenv<20.16.4
|
||
|
||
[testenv]
|
||
install_command = pip install {opts} {packages}
|
||
whitelist_externals =
|
||
/bin/sh
|
||
deps =
|
||
-c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/train}
|
||
-r{toxinidir}/test-requirements.txt
|
||
-r{toxinidir}/requirements.txt
|
||
commands = stestr run --slowest {posargs}
|
||
|
||
[testenv:py27]
|
||
basepython = python2.7
|
||
|
||
[testenv:pep8]
|
||
basepython = python3
|
||
deps =
|
||
-r{toxinidir}/test-requirements.txt
|
||
commands =
|
||
flake8
|
||
# Run security linter
|
||
bandit -r oslo_privsep -x tests -n5 --skip B404,B603
|
||
|
||
[testenv:venv]
|
||
basepython = python3
|
||
commands = {posargs}
|
||
|
||
[testenv:docs]
|
||
basepython = python3
|
||
whitelist_externals =
|
||
rm
|
||
deps =
|
||
{[testenv]deps}
|
||
-r{toxinidir}/doc/requirements.txt
|
||
commands =
|
||
rm -rf doc/build
|
||
sphinx-build -W -b html doc/source doc/build/html
|
||
|
||
[testenv:cover]
|
||
basepython = python3
|
||
setenv =
|
||
PYTHON=coverage run --source $project --parallel-mode
|
||
commands =
|
||
stestr run {posargs}
|
||
coverage combine
|
||
coverage html -d cover
|
||
coverage xml -o cover/coverage.xml
|
||
|
||
[flake8]
|
||
# E123, E125 skipped as they are invalid PEP-8.
|
||
# [H106] Don’t put vim configuration in source files
|
||
# [H203] Use assertIs(Not)None to check for None
|
||
|
||
show-source = True
|
||
ignore = E123,E125
|
||
builtins = _
|
||
exclude=.venv,.git,.tox,dist,doc,*lib/python*,*egg,build
|
||
enable-extensions = H106,H203
|
||
|
||
[hacking]
|
||
import_exceptions =
|
||
oslo_privsep._i18n
|
||
|
||
[testenv:releasenotes]
|
||
basepython = python3
|
||
commands = sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html
|
||
|
||
[testenv:lower-constraints]
|
||
basepython = python3
|
||
deps =
|
||
-c{toxinidir}/lower-constraints.txt
|
||
-r{toxinidir}/test-requirements.txt
|
||
-r{toxinidir}/requirements.txt
|