diff --git a/tox.ini b/tox.ini new file mode 100644 index 000000000..8e5ddd2c3 --- /dev/null +++ b/tox.ini @@ -0,0 +1,39 @@ +# Tox (https://tox.readthedocs.io) is a tool for running tests +# in multiple virtualenvs. This configuration file will run the +# test suite on all supported python versions. To use it, "pip install tox" +# and then run "tox" from this directory. + +[tox] +envlist = py27, py34, py35, py36, py37, flake8-27, flake8-37 +minversion = 2.5.0 +skip_missing_interpreters = true +requires = tox-venv + +[testenv] +deps = + -rrequirements.txt + pytest +commands = + python -m pytest {posargs} +extras = test + +[testenv:flake8-27] +basepython = python2.7 +deps = flake8 +commands = + flake8 . --count --select=E722,F401,F811,E901, \ + E999,F821,F822,F823 --show-source --statistics + - flake8 . --count --max-complexity=10 \ + --max-line-length=79 --statistics +skip_install = True + +[testenv:flake8-37] +basepython = python3.7 +deps = flake8 +commands = + flake8 . --count --select=E722,F401,F811,E901, \ + E999,F821,F822,F823 --show-source --statistics + - flake8 . --count --max-complexity=10 \ + --max-line-length=79 --statistics +skip_install = True +