71 lines
2.0 KiB
INI
71 lines
2.0 KiB
INI
[tox]
|
|
minversion = 3.1.0
|
|
envlist = py3,pep8
|
|
|
|
[testenv]
|
|
setenv =
|
|
VIRTUAL_ENV={envdir}
|
|
OS_STDOUT_CAPTURE=1
|
|
OS_STDERR_CAPTURE=1
|
|
OS_TEST_TIMEOUT=60
|
|
commands =
|
|
stestr run {posargs}
|
|
stestr slowest
|
|
deps =
|
|
-c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
|
|
-r{toxinidir}/test-requirements.txt
|
|
-r{toxinidir}/requirements.txt
|
|
|
|
[testenv:pep8]
|
|
description =
|
|
Run style checks.
|
|
skip_install = true
|
|
deps =
|
|
pre-commit
|
|
commands =
|
|
pre-commit run --all-files --show-diff-on-failure
|
|
|
|
[testenv:venv]
|
|
# TODO(modred) remove doc/requirements.txt once the openstack-build-sphinx-docs
|
|
# job is updated.
|
|
deps =
|
|
-r{toxinidir}/test-requirements.txt
|
|
-r{toxinidir}/doc/requirements.txt
|
|
commands = {posargs}
|
|
|
|
[testenv:neutronclient-tip]
|
|
deps = os:openstack/python-neutronclient:python-neutronclient
|
|
commands = {toxinidir}/integration-tests/neutronclient-tip.sh {envdir}
|
|
|
|
[testenv:openstackclient-tip]
|
|
deps = os:openstack/python-openstackclient:python-openstackclient
|
|
commands = {toxinidir}/integration-tests/openstackclient-tip.sh {envdir}
|
|
|
|
[testenv:docs]
|
|
deps =
|
|
-c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
|
|
-r{toxinidir}/doc/requirements.txt
|
|
commands = sphinx-build -W -b html doc/source doc/build/html
|
|
|
|
[testenv:cover]
|
|
setenv =
|
|
{[testenv]setenv}
|
|
PYTHON=coverage run --source cliff --parallel-mode
|
|
commands =
|
|
stestr run {posargs}
|
|
coverage combine
|
|
coverage html -d cover
|
|
coverage xml -o cover/coverage.xml
|
|
|
|
[flake8]
|
|
application-import-names = cliff
|
|
# E203 Black will put spaces after colons in list comprehensions
|
|
# E501 Black takes care of line length for us
|
|
# W503 Is supposed to be off by default but in the latest pycodestyle isn't.
|
|
# Also, both openstacksdk and Donald Knuth disagree with the rule. Line
|
|
# breaks should occur before the binary operator for readability.
|
|
ignore = E203, E501, W503
|
|
import-order-style = pep8
|
|
show-source = true
|
|
exclude = .venv,.git,.tox,dist,doc,*lib/python*,*egg,build
|