2010-07-23 04:37:44 -05:00
|
|
|
[tox]
|
2017-12-19 09:55:10 -06:00
|
|
|
minversion = 2.0
|
|
|
|
envlist = docs,flake8,mypy,coverage,py{27,34,35,36,py},du{11,12,13,14}
|
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 =
|
|
|
|
py{27,34,35,36,py}: Run unit tests against {envname}.
|
|
|
|
du{11,12,13,14}: Run unit tests with the given version of docutils.
|
|
|
|
|
2017-10-10 08:10:11 -05:00
|
|
|
# TODO(stephenfin) Replace this with the 'extras' config option when tox 2.4 is
|
|
|
|
# widely available, likely some time after the Ubuntu 18.04 release
|
|
|
|
#
|
|
|
|
# https://tox.readthedocs.io/en/latest/config.html#confval-extras=MULTI-LINE-LIST
|
|
|
|
deps =
|
|
|
|
.[test,websupport]
|
2017-10-27 04:11:10 -05:00
|
|
|
du11: docutils==0.11
|
|
|
|
du12: docutils==0.12
|
|
|
|
du13: docutils==0.13.1
|
|
|
|
du14: docutils==0.14
|
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
|
2014-09-21 10:17:02 -05:00
|
|
|
SPHINX_TEST_TEMPDIR = {envdir}/testbuild
|
2010-07-23 05:16:17 -05:00
|
|
|
commands=
|
2017-12-22 12:50:51 -06:00
|
|
|
pytest -Wall --durations 25 {posargs}
|
2010-07-23 05:16:17 -05:00
|
|
|
|
2015-03-07 00:45:43 -06:00
|
|
|
[testenv:flake8]
|
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]
|
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]
|
|
|
|
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]
|
2017-12-19 09:55:10 -06:00
|
|
|
description =
|
|
|
|
Run type checks.
|
|
|
|
deps =
|
2017-02-28 11:31:31 -06:00
|
|
|
mypy
|
|
|
|
commands=
|
|
|
|
mypy sphinx/
|
|
|
|
|
2017-02-24 12:25:51 -06:00
|
|
|
[testenv:docs]
|
2017-12-19 09:55:10 -06:00
|
|
|
description =
|
|
|
|
Build documentation.
|
|
|
|
commands =
|
2017-10-03 04:25:10 -05:00
|
|
|
python setup.py build_sphinx {posargs}
|