2010-07-23 04:37:44 -05:00
|
|
|
[tox]
|
2018-11-11 11:33:17 -06:00
|
|
|
minversion = 2.4.0
|
2020-07-04 11:32:54 -05:00
|
|
|
envlist = docs,flake8,mypy,twine,coverage,py{36,37,38,39},du{14,15,16}
|
2010-07-23 04:37:44 -05:00
|
|
|
|
|
|
|
[testenv]
|
2018-01-05 07:25:34 -06:00
|
|
|
usedevelop = True
|
2017-12-19 09:55:10 -06:00
|
|
|
passenv =
|
2020-03-03 16:09:13 -06:00
|
|
|
https_proxy
|
|
|
|
http_proxy
|
|
|
|
no_proxy
|
|
|
|
PERL
|
|
|
|
PERL5LIB
|
|
|
|
PYTEST_ADDOPTS
|
|
|
|
EPUBCHECK_PATH
|
|
|
|
TERM
|
2017-12-19 09:55:10 -06:00
|
|
|
description =
|
2020-03-06 19:08:46 -06:00
|
|
|
py{36,37,38,39}: Run unit tests against {envname}.
|
2018-08-24 08:01:41 -05:00
|
|
|
du{12,13,14}: Run unit tests with the given version of docutils.
|
2017-10-10 08:10:11 -05:00
|
|
|
deps =
|
2017-10-27 04:11:10 -05:00
|
|
|
du14: docutils==0.14
|
2019-07-21 10:35:28 -05:00
|
|
|
du15: docutils==0.15
|
2020-01-22 09:50:57 -06:00
|
|
|
du16: docutils==0.16
|
2018-11-11 11:33:17 -06:00
|
|
|
extras =
|
|
|
|
test
|
2012-05-01 01:21:12 -05:00
|
|
|
setenv =
|
2020-12-29 04:09:15 -06:00
|
|
|
PYTHONWARNINGS = all,ignore::ImportWarning:importlib._bootstrap_external,ignore::DeprecationWarning:site,ignore::DeprecationWarning:distutils,ignore::DeprecationWarning:pip._vendor.packaging.version
|
2020-11-04 10:00:54 -06:00
|
|
|
PYTEST_ADDOPTS = {env:PYTEST_ADDOPTS:} --color yes
|
2010-07-23 05:16:17 -05:00
|
|
|
commands=
|
2020-11-11 07:16:34 -06:00
|
|
|
python -X dev -m pytest --durations 25 {posargs}
|
2010-07-23 05:16:17 -05:00
|
|
|
|
2015-03-07 00:45:43 -06:00
|
|
|
[testenv:flake8]
|
2018-06-20 03:53:29 -05:00
|
|
|
basepython = python3
|
2017-12-19 09:55:10 -06:00
|
|
|
description =
|
|
|
|
Run style checks.
|
2020-02-10 16:25:54 -06:00
|
|
|
whitelist_externals =
|
|
|
|
flake8
|
2020-01-22 09:42:59 -06:00
|
|
|
extras =
|
|
|
|
lint
|
2017-12-19 09:55:10 -06:00
|
|
|
commands =
|
2020-02-10 16:25:54 -06:00
|
|
|
flake8 {posargs}
|
2015-11-09 20:40:48 -06:00
|
|
|
|
2020-11-11 05:00:27 -06:00
|
|
|
[testenv:isort]
|
|
|
|
basepython = python3
|
|
|
|
description =
|
|
|
|
Run import sorting checks.
|
|
|
|
whitelist_externals =
|
|
|
|
isort
|
|
|
|
extras =
|
|
|
|
lint
|
|
|
|
commands =
|
|
|
|
isort --check-only --diff .
|
|
|
|
|
2017-12-22 12:00:25 -06:00
|
|
|
[testenv:coverage]
|
2018-06-20 03:53:29 -05:00
|
|
|
basepython = python3
|
2017-12-22 12:00:25 -06:00
|
|
|
description =
|
|
|
|
Run code coverage checks.
|
|
|
|
setenv =
|
|
|
|
PYTEST_ADDOPTS = --cov sphinx --cov-config {toxinidir}/setup.cfg
|
|
|
|
commands =
|
|
|
|
{[testenv]commands}
|
|
|
|
coverage report
|
|
|
|
|
2017-02-28 11:31:31 -06:00
|
|
|
[testenv:mypy]
|
2018-06-20 03:53:29 -05:00
|
|
|
basepython = python3
|
2017-12-19 09:55:10 -06:00
|
|
|
description =
|
|
|
|
Run type checks.
|
2020-01-22 09:42:59 -06:00
|
|
|
extras =
|
|
|
|
lint
|
2017-02-28 11:31:31 -06:00
|
|
|
commands=
|
|
|
|
mypy sphinx/
|
|
|
|
|
2017-02-24 12:25:51 -06:00
|
|
|
[testenv:docs]
|
2018-06-20 03:53:29 -05:00
|
|
|
basepython = python3
|
2017-12-19 09:55:10 -06:00
|
|
|
description =
|
|
|
|
Build documentation.
|
2019-05-03 22:42:17 -05:00
|
|
|
extras =
|
|
|
|
docs
|
2017-12-19 09:55:10 -06:00
|
|
|
commands =
|
2017-10-03 04:25:10 -05:00
|
|
|
python setup.py build_sphinx {posargs}
|
2018-01-19 07:55:17 -06:00
|
|
|
|
2019-05-12 03:57:25 -05:00
|
|
|
[testenv:docslint]
|
|
|
|
basepython = python3
|
|
|
|
description =
|
|
|
|
Lint documentation.
|
|
|
|
extras =
|
|
|
|
docs
|
|
|
|
commands =
|
|
|
|
python utils/doclinter.py CHANGES CONTRIBUTING.rst README.rst doc/
|
|
|
|
|
2020-06-13 23:38:55 -05:00
|
|
|
[testenv:twine]
|
|
|
|
basepython = python3
|
|
|
|
description =
|
|
|
|
Lint package.
|
|
|
|
deps =
|
|
|
|
twine
|
|
|
|
commands =
|
|
|
|
python setup.py release bdist_wheel sdist
|
|
|
|
twine check dist/*
|
|
|
|
|
2018-01-19 07:55:17 -06:00
|
|
|
[testenv:bindep]
|
|
|
|
description =
|
|
|
|
Install binary dependencies.
|
|
|
|
deps =
|
|
|
|
bindep
|
|
|
|
commands =
|
|
|
|
bindep test
|