shipyard/src/bin/shipyard_client/tox.ini

86 lines
1.6 KiB
INI

[tox]
skipsdist=True
envlist = py38, pep8, bandit
[testenv]
setenv=
PYTHONWARNING=all
LC_ALL=C.UTF-8
LC_ALL=C.UTF-8
deps =
-r{toxinidir}/requirements-frozen.txt
-r{toxinidir}/test-requirements.txt
[testenv:freeze-bionic]
recreate = True
allowlist_externals=
rm
sh
deps=
-r{toxinidir}/requirements-direct.txt
commands=
rm -f {toxinidir}/requirements-frozen-bionic.txt
sh -c "pip freeze --all | grep -vE 'shipyard_airflow|pyinotify|pkg-resources' > requirements-frozen-bionic.txt"
[testenv:freeze]
recreate = True
allowlist_externals=
rm
sh
deps=
-r{toxinidir}/requirements-direct.txt
commands=
rm -f {toxinidir}/requirements-frozen.txt
sh -c "pip freeze --all | grep -vE 'shipyard_airflow|pyinotify|pkg-resources' > requirements-frozen.txt"
[testenv:py36]
skipsdist=True
deps =
-r{toxinidir}/requirements-frozen-bionic.txt
-r{toxinidir}/test-requirements.txt
commands =
pytest \
{posargs} \
-vv
[testenv:py38]
skipsdist=True
commands =
pytest \
{posargs} \
-vv
[testenv:cover]
skipsdist=True
commands =
pytest \
{posargs} \
--cov-branch \
--cov-report=term-missing:skip-covered \
--cov-config=.coveragerc \
--cov=shipyard_client \
--cov-report=html \
-vv
[testenv:pep8]
deps=
flake8>=3.3.0
bandit>=1.5.0
commands =
flake8 {toxinidir}/shipyard_client
bandit -r shipyard_airflow
[testenv:bandit]
skipsdist=True
commands =
bandit -r shipyard_client -n 5
[flake8]
filename = *.py
# W504 line break after binary operator
# TODO(rb560u): Address E722 violations
ignore = F841,W504,E722
exclude = .venv,.git,.tox,build,dist,*lib/python*,*egg,docs