815b66364b
Sphinx 1.8 introduced [1] the '--keep-going' argument which, as its name suggests, keeps the build running when it encounters non-fatal errors. This is exceptionally useful in avoiding a continuous edit-build loop when undertaking large doc reworks where multiple errors may be introduced. [1] https://github.com/sphinx-doc/sphinx/commit/e3483e9b045 Change-Id: I18032bd40489c4b1c511713b0f1c5bb1aca7c1d2
96 lines
2.2 KiB
INI
96 lines
2.2 KiB
INI
[tox]
|
|
envlist = py36,py37,pep8,pylint,docs
|
|
skipsdist = True
|
|
|
|
[testenv]
|
|
basepython = python3
|
|
usedevelop = True
|
|
deps =
|
|
-c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
|
|
-r{toxinidir}/requirements.txt
|
|
-r{toxinidir}/test-requirements.txt
|
|
|
|
passenv =
|
|
FREEZER_TEST_SSH_KEY
|
|
FREEZER_TEST_SSH_USERNAME
|
|
FREEZER_TEST_SSH_HOST
|
|
FREEZER_TEST_CONTAINER
|
|
FREEZER_TEST_OS_TENANT_NAME
|
|
FREEZER_TEST_OS_USERNAME
|
|
FREEZER_TEST_OS_REGION_NAME
|
|
FREEZER_TEST_OS_PASSWORD
|
|
FREEZER_TEST_OS_AUTH_URL
|
|
FREEZER_TEST_NO_LVM
|
|
http_proxy HTTP_PROXY https_proxy HTTPS_PROXY no_proxy NO_PROXY
|
|
|
|
install_command = pip install {opts} {packages}
|
|
setenv =
|
|
VIRTUAL_ENV={envdir}
|
|
OS_TEST_PATH = ./freezer/tests/unit
|
|
PYTHON=coverage run --source freezer --parallel-mode
|
|
commands =
|
|
find . -type f -name "*.pyc" -delete
|
|
stestr run {posargs}
|
|
coverage combine
|
|
coverage html -d cover
|
|
coverage xml -o cover/coverage.xml
|
|
coverage report -m
|
|
rm -f .coverage
|
|
rm -rf .testrepository
|
|
|
|
whitelist_externals =
|
|
find
|
|
coverage
|
|
rm
|
|
|
|
python_files = test_*.py
|
|
norecursedirs = .tox .venv
|
|
|
|
[testenv:venv]
|
|
commands = {posargs}
|
|
|
|
[testenv:py37]
|
|
basepython = python3.7
|
|
|
|
[testenv:py36]
|
|
basepython = python3.6
|
|
|
|
[testenv:docs]
|
|
deps = -r{toxinidir}/doc/requirements.txt
|
|
whitelist_externals = rm
|
|
commands =
|
|
rm -rf doc/build/
|
|
sphinx-build --keep-going -b html doc/source doc/build/html
|
|
|
|
|
|
[testenv:pep8]
|
|
commands =
|
|
flake8 freezer
|
|
doc8 {posargs}
|
|
|
|
[testenv:pylint]
|
|
commands = pylint --rcfile .pylintrc freezer
|
|
|
|
[flake8]
|
|
ignore = H405,H404,H403,H401
|
|
show-source = True
|
|
enable-extensions = H203,H106
|
|
exclude = .venv,.tox,dist,doc,test,*egg,releasenotes
|
|
|
|
[doc8]
|
|
ignore = D000,D001
|
|
ignore-path = .venv,.git,.tox,.tmp,*freezer/locale*,*lib/python*,freezer.egg*,doc/build,releasenotes/*,doc/source/contributor/api
|
|
|
|
[testenv:releasenotes]
|
|
deps = -r{toxinidir}/doc/requirements.txt
|
|
whitelist_externals = rm
|
|
commands =
|
|
rm -rf releasenotes/build
|
|
sphinx-build -a -E -d releasenotes/build/doctrees --keep-going -b html releasenotes/source releasenotes/build/html
|
|
|
|
[testenv:lower-constraints]
|
|
deps =
|
|
-c{toxinidir}/lower-constraints.txt
|
|
-r{toxinidir}/test-requirements.txt
|
|
-r{toxinidir}/requirements.txt
|