# Tox (http://tox.testrun.org/) 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 = py26, py27, py32, py33, py34, py35, pypy, pypy3, coverage, pep8

[testenv]
commands = py.test
deps = pytest


[testenv:py27]
commands = py.test --doctest-glob=README.rst  # test documentation
deps = pytest

[testenv:pep8]
# pep8 disabled for E701 (multiple statements on one line) and E126 (continuation line over-indented for hanging indent)
commands = flake8 --max-line-length=90 --show-source -v --count --ignore=E701,E126
deps = flake8

[testenv:coverage]
#TODO: how to force this on py27?
commands = coverage erase
           py.test --doctest-glob=README.rst --cov schema
           coverage report -m
deps = pytest
       pytest-cov
       coverage

[flake8]
exclude=.venv,.git,.tox
