# 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]
minversion = 3.7.0
envlist = lint, py36, py37, py38, py39, py310, pypy3
skip_missing_interpreters = true
isolated_build = true

[testenv]
depends = lint
commands = coverage run -m pytest {posargs}
extras = test
    trio

[testenv:lint]
depends =
basepython = python3
deps = pre-commit
commands = pre-commit run --all-files --show-diff-on-failure
skip_install = true

[testenv:docs]
depends =
extras = doc
commands = sphinx-build docs build/sphinx
