1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70
|
[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
|