porthole/tox.ini
Sergiy Markin 5e2b42297c [utility] Database utility charts
This PS bumps up database utility charts version in order to make sure
smooth upgrade will happen from previous versions.

Also in this PS were included several tox4 related changes.

Change-Id: I888b7186f0a10e83dd7af6a419c6d933ad0fc65b
2023-03-03 02:57:00 +00:00

78 lines
1.8 KiB
INI

[tox]
minversion = 3.4
envlist = dev,pep8,py38,bandit,docs,list-tests
skipsdist = true
[testenv:dev]
useddevelop = True
basepython = python3
passenv =
http_proxy
HTTP_PROXY
https_proxy
HTTPS_PROXY
no_proxy
NO_PROXY
allowlist_externals = find
setenv =
VIRTUAL_ENV={envdir}
PYTHONWARNINGS=default::DeprecationWarning
deps =
freeze-req: -r{toxinidir}/requirements-frozen.txt
list-tests: -r {toxinidir}/requirements-frozen.txt
envdir=
{toxinidir}/.tox/{envname}
commands_pre =
find . -type f -name "*.pyc"
list-tests: stestr init
[testenv:venv]
commands = {posargs}
[testenv:py38]
setenv =
PYTHONWARNING=all
deps = -r{toxinidir}/requirements-frozen.txt
-r{toxinidir}/test-requirements.txt
commands =
pytest {posargs}
[testenv:bandit]
deps =
-r{toxinidir}/test-requirements.txt
commands =
bandit -r {toxinidir}
[testenv:docs]
allowlist_externals = rm
deps =
-r{toxinidir}/docs/requirements.txt
commands =
rm -rf docs/build
sphinx-build -W -b html docs/source docs/build/html
[testenv:pep8]
deps =
-r{toxinidir}/test-requirements.txt
commands =
yapf -rd {toxinidir} {toxinidir}/tests
flake8 {toxinidir}
bandit -r {toxinidir}
[flake8]
# [H106] Don't put vim configuration in source files.
# [H203] Use assertIs(Not)None to check for None.
# [H204] Use assert(Not)Equal to check for equality.
# [H205] Use assert(Greater|Less)(Equal) for comparison.
# [H210] Require 'autospec', 'spec', or 'spec_set' in mock.patch/mock.patch.object calls
# [H904] Delay string interpolations at logging calls.
enable-extensions = H106,H203,H204,H205,H210
# [E731] Do not assign a lambda expression, use a def. This reduces readability in some cases.
ignore = E126,E731,F405,H102,H301,H306,H401,H404,H405,H904,W503,W504
exclude = .venv,.git,.tox,dist,*lib/python*,*egg,build,releasenotes,doc,alembic/versions