cd0daf743e
Fix pylint by specifying a nodeset that contains a python3 interpreter. Switched the job to run py3. This application needs to be installed into the virtualenv in order for its entry points to be discoverable by stevedore for the unit tests. However py27 fails to find pbr during the sdist phase since the zuul node is running a py35 virtualenv. Disabling sdist should get pip to work. Other tox settings should install it properly in the virtualenv. Story: 2008943 Task: 43010 Signed-off-by: albailey <Al.Bailey@windriver.com> Change-Id: I834a414f90d16d303c499e9ec3799ca5d02ca425
53 lines
1.2 KiB
INI
53 lines
1.2 KiB
INI
[tox]
|
|
envlist = linters
|
|
minversion = 2.3
|
|
skipsdist = True
|
|
sitepackages=False
|
|
|
|
[testenv]
|
|
install_command = pip install -U {opts} {packages}
|
|
setenv =
|
|
VIRTUAL_ENV={envdir}
|
|
OS_STDOUT_CAPTURE=1
|
|
OS_STDERR_CAPTURE=1
|
|
OS_DEBUG=1
|
|
OS_LOG_CAPTURE=1
|
|
deps =
|
|
-r{toxinidir}/requirements.txt
|
|
-r{toxinidir}/test-requirements.txt
|
|
whitelist_externals =
|
|
bash
|
|
|
|
passenv =
|
|
XDG_CACHE_HOME
|
|
|
|
|
|
[testenv:bashate]
|
|
# Treat all E* codes as Errors rather than warnings using: -e 'E*'
|
|
commands =
|
|
bash -c "find {toxinidir} \
|
|
-not \( -type d -name .?\* -prune \) \
|
|
-type f \
|
|
-not -name \*~ \
|
|
-not -name \*.md \
|
|
-name \*.sh \
|
|
-print0 | xargs -r -n 1 -0 bashate -v \
|
|
-e 'E*'"
|
|
|
|
[testenv:linters]
|
|
commands =
|
|
{[testenv:bashate]commands}
|
|
|
|
[testenv:flake8]
|
|
basepython = python3
|
|
description = Dummy environment to allow flake8 to be run in subdir tox
|
|
|
|
[testenv:pylint]
|
|
basepython = python3
|
|
description = Dummy environment to allow pylint to be run in subdir tox
|
|
|
|
[testenv:bandit]
|
|
basepython = python3
|
|
description = Dummy environment to allow bandit to be run in subdir tox
|
|
|