Charmed-Kubernetes/calico/tox.ini

48 lines
1.4 KiB
INI

[flake8]
max-line-length = 88
[tox]
skipsdist = True
envlist = lint,unit,integration
[testenv]
setenv =
PYTHONPATH={toxinidir}:{toxinidir}/lib
PYTHONBREAKPOINT=ipdb.set_trace
[testenv:unit]
deps =
pyyaml
pytest
charms.unit_test
ipdb
commands = pytest --tb native -s {posargs} {toxinidir}/tests/unit
[testenv:validate-wheelhouse]
deps =
# Temporarily pin setuptools to avoid the breaking change from 58 until
# all dependencies we use have a chance to update. (tempita is the troublemaker for this repo).
# See: https://setuptools.readthedocs.io/en/latest/history.html#v58-0-0
# and: https://github.com/pypa/setuptools/issues/2784#issuecomment-917663223
setuptools<58
allowlist_externals = {toxinidir}/tests/validate-wheelhouse.sh
commands = {toxinidir}/tests/validate-wheelhouse.sh
[testenv:integration]
deps =
pytest
pytest-operator
aiohttp
ipdb
git+https://github.com/canonical/kubernetes-rapper@main#egg=kubernetes-wrapper
# tox only passes through the upper-case versions by default, but some
# programs, such as wget or pip, only honor the lower-case versions
passenv = http_proxy https_proxy no_proxy
commands = pytest --asyncio-mode=auto --tb native --show-capture=no --log-cli-level=INFO -s {posargs} {toxinidir}/tests/integration
[testenv:lint]
deps =
flake8
commands =
flake8 {toxinidir}/reactive {toxinidir}/lib {toxinidir}/tests