[tox] envlist = py3,flake8 minversion = 3.1.0 skip_missing_interpreters = true # this allows tox to infer the base python from the environment name # and override any basepython configured in this file ignore_basepython_conflict = true [testenv] usedevelop = True install_command = pip install {opts} {packages} setenv = VIRTUAL_ENV={envdir} LANG=en_US.UTF-8 LANGUAGE=en_US:en LC_ALL=C deps = -c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master} -r{toxinidir}/requirements.txt -r{toxinidir}/test-requirements.txt allowlist_externals = find sh rm commands = find . -type f -name "*.pyc" -delete stestr run --slowest {posargs} passenv = http_proxy HTTP_PROXY https_proxy HTTPS_PROXY no_proxy NO_PROXY [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:flake8] commands = flake8 [testenv:pep8] commands = flake8 [testenv:pyflakes] commands = flake8 [testenv:cover] setenv = PYTHON=coverage run --source designateclient --parallel-mode commands = stestr run {posargs} coverage combine coverage html -d cover coverage xml -o cover/coverage.xml [testenv:venv] commands = {posargs} [testenv:functional] usedevelop = False setenv = {[testenv]setenv} OS_TEST_PATH=designateclient/functionaltests/ passenv = OS_STDOUT_CAPTURE OS_STDERR_CAPTURE OS_LOG_CAPTURE OS_DEBUG TEMPEST_CONFIG [testenv:functional-py36] setenv = {[testenv:functional]setenv} [testenv:functional-py37] setenv = {[testenv:functional]setenv} [testenv:functional-py38] setenv = {[testenv:functional]setenv} [testenv:releasenotes] deps = -c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master} -r{toxinidir}/doc/requirements.txt commands = sphinx-build -a -E -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html [flake8] # ignored flake8 codes: # H302 import only modules # H404 multi line docstring should start with a summary # H405 multi line docstring summary not separated with an empty line # H904 Wrap long lines in parentheses instead of a backslash # W504 line break after binary operator # See designate for other ignored codes that may apply here ignore = H105,H302,H404,H405,W504,H904 builtins = _ exclude = .venv,.git,.tox,dist,doc,*openstack/common*,*lib/python*,*egg,build,tools [flake8:local-plugins] extension = D701 = checks:mutable_default_arguments D703 = checks:check_explicit_underscore_import D704 = checks:no_import_graduated_oslo_libraries D705 = checks:use_timeutils_utcnow D706 = checks:no_translate_debug_logs D707 = checks:check_no_basestring D708 = checks:check_python3_xrange D709 = checks:check_no_log_audit D710 = checks:check_no_log_warn D711 = checks:check_line_continuation_no_backslash paths = ./designateclient/hacking