2010-07-23 04:37:44 -05:00
|
|
|
[tox]
|
2018-11-11 11:33:17 -06:00
|
|
|
minversion = 2.4.0
|
2020-01-22 09:54:49 -06:00
|
|
|
envlist = docs,flake8,mypy,coverage,py{35,36,37,38,39},du{12,13,14,15}
|
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 =
|
2018-03-20 09:35:32 -05:00
|
|
|
https_proxy http_proxy no_proxy PERL PERL5LIB PYTEST_ADDOPTS EPUBCHECK_PATH
|
2017-12-19 09:55:10 -06:00
|
|
|
description =
|
2020-01-22 09:54:49 -06:00
|
|
|
py{35,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 =
|
2019-12-15 02:47:57 -06:00
|
|
|
coverage < 5.0 # refs: https://github.com/sphinx-doc/sphinx/pull/6924
|
2020-01-22 09:54:49 -06:00
|
|
|
git+https://github.com/html5lib/html5lib-python ; python_version >= "3.9" # refs: https://github.com/html5lib/html5lib-python/issues/419
|
2017-10-27 04:11:10 -05:00
|
|
|
du12: docutils==0.12
|
|
|
|
du13: docutils==0.13.1
|
|
|
|
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 =
|
2018-01-14 16:02:53 -06:00
|
|
|
PYTHONWARNINGS = all,ignore::ImportWarning:pkgutil,ignore::ImportWarning:importlib._bootstrap,ignore::ImportWarning:importlib._bootstrap_external,ignore::ImportWarning:pytest_cov.plugin,ignore::DeprecationWarning:site,ignore::DeprecationWarning:_pytest.assertion.rewrite,ignore::DeprecationWarning:_pytest.fixtures,ignore::DeprecationWarning:distutils
|
2010-07-23 05:16:17 -05:00
|
|
|
commands=
|
2018-10-29 09:59:31 -05:00
|
|
|
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.
|
|
|
|
commands =
|
|
|
|
flake8
|
2015-11-09 20:40:48 -06:00
|
|
|
|
2017-10-05 03:16:05 -05:00
|
|
|
[testenv:pylint]
|
2018-06-20 03:53:29 -05:00
|
|
|
basepython = python3
|
2017-12-19 09:55:10 -06:00
|
|
|
description =
|
|
|
|
Run source code analyzer.
|
|
|
|
deps =
|
2017-10-05 03:16:05 -05:00
|
|
|
pylint
|
|
|
|
{[testenv]deps}
|
2017-12-19 09:55:10 -06:00
|
|
|
commands =
|
2017-10-05 03:16:05 -05:00
|
|
|
pylint --rcfile utils/pylintrc sphinx
|
|
|
|
|
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.
|
|
|
|
deps =
|
2017-02-28 11:31:31 -06:00
|
|
|
mypy
|
2018-12-03 10:52:07 -06:00
|
|
|
docutils-stubs
|
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/
|
|
|
|
|
2018-01-19 07:55:17 -06:00
|
|
|
[testenv:bindep]
|
|
|
|
description =
|
|
|
|
Install binary dependencies.
|
|
|
|
deps =
|
|
|
|
bindep
|
|
|
|
commands =
|
|
|
|
bindep test
|