blob: 9bfc5ae74fe5c25fb4da6f5ba07327481a313685 [file] [log] [blame]
[tox]
minversion = 3.4.0
envlist = {py27, py35, py36, py37, py38}-{unittest}, conver, bandit, build
isolated_build = true
skip_missing_interpreters = true
[testenv]
usedevelop = True
setenv =
VIRTUAL_ENV={envdir}
PYTHONWARNINGS=default::DeprecationWarning
deps = pip >= 19.3.1
install_command =
pip install {opts} {packages}
[testenv:unittest]
deps =
{[testenv]deps}
discover
-r{toxinidir}/requirements.txt
commands =
discover -s examples/pyasn1_modules-example-switch/tests -s tests
[testenv:py27-unittest]
deps = {[testenv:unittest]deps}
commands = {[testenv:unittest]commands}
[testenv:py35-unittest]
deps = {[testenv:unittest]deps}
commands = {[testenv:unittest]commands}
[testenv:py36-unittest]
deps = {[testenv:unittest]deps}
commands = {[testenv:unittest]commands}
[testenv:py37-unittest]
deps = {[testenv:unittest]deps}
commands = {[testenv:unittest]commands}
[testenv:py38-unittest]
deps = {[testenv:unittest]deps}
commands = {[testenv:unittest]commands}
[testenv:cover]
basepython = python3.7
setenv =
{[testenv]setenv}
PYTHON=coverage run --parallel-mode
deps =
{[testenv:unittest]deps}
coverage
discover
commands = coverage erase
coverage run --source pyasn1_modules -m unittest discover {posargs}
coverage report --fail-under 80
[testenv:bandit]
skip_install = true
deps =
bandit
commands =
bandit -r pyasn1_modules -c .bandit.yml
[testenv:build]
skip_install = true
deps =
wheel
setuptools
commands =
python setup.py -q sdist bdist_wheel