[tox]
envlist=flake8,py3
toxworkdir={env:TOXINI_WORK_DIR:{toxinidir}/.tox}
skipsdist=True
[_vars]
build_root={env:TOXINI_ARTEFACT_DIR:{toxinidir}/build}
[testenv]
passenv=
    COVERAGE_FILE
deps=
    coverage
setenv=
    TOX_STATIC_ROOT={[_vars]build_root}/static
commands=
    coverage run --source={toxinidir} -m pytest
    coverage html --directory {[_vars]build_root}/htmlcov/
    coverage report
    coverage xml -o {env:COVERAGE_XML_FILE:{[_vars]build_root}/coverage.xml}
sitepackages={env:TOXINI_SITEPACKAGES:true}
[testenv:py3]
basepython=python3
[testenv:flake8]
deps=
    flake8=={env:TOXINI_FLAKE8_VERSION:4.0.1}
basepython=python3
commands=
    flake8 .
