2013-01-24 17:42:57 +00:00
|
|
|
[tox]
|
2022-09-02 06:14:09 +00:00
|
|
|
envlist = pep8,linters,py3
|
2021-05-03 11:14:41 +00:00
|
|
|
minversion = 3.18.0
|
2020-06-05 07:51:28 +00:00
|
|
|
ignore_basepython_conflict = True
|
2013-01-24 17:42:57 +00:00
|
|
|
|
|
|
|
[testenv]
|
2013-12-09 14:23:46 +00:00
|
|
|
usedevelop = True
|
2017-12-01 06:44:18 +00:00
|
|
|
deps=
|
|
|
|
-r{toxinidir}/requirements.txt
|
2014-01-16 08:43:21 +00:00
|
|
|
-r{toxinidir}/test-requirements.txt
|
2021-05-03 11:14:41 +00:00
|
|
|
commands= stestr run --slowest {posargs}
|
2017-06-08 04:15:07 +00:00
|
|
|
passenv=
|
|
|
|
DUMP_CONFIG_GRAPH
|
2013-01-24 17:42:57 +00:00
|
|
|
|
2018-05-25 03:36:12 +00:00
|
|
|
[testenv:bindep]
|
|
|
|
deps = bindep
|
|
|
|
commands = bindep test
|
|
|
|
|
2022-09-02 06:14:09 +00:00
|
|
|
[testenv:linters]
|
2013-06-20 05:32:55 +00:00
|
|
|
commands =
|
2022-09-02 06:14:09 +00:00
|
|
|
pylint --rcfile pylint.cfg diskimage_builder
|
2013-06-20 05:32:55 +00:00
|
|
|
flake8 {posargs}
|
2014-03-20 01:56:27 +00:00
|
|
|
dib-lint
|
2013-01-24 17:42:57 +00:00
|
|
|
|
|
|
|
[testenv:venv]
|
|
|
|
commands = {posargs}
|
|
|
|
|
2015-09-30 09:55:40 +00:00
|
|
|
[testenv:func]
|
|
|
|
envdir = {toxworkdir}/venv
|
|
|
|
commands = {toxinidir}/tests/run_functests.sh {posargs}
|
|
|
|
|
2013-01-24 17:42:57 +00:00
|
|
|
[testenv:cover]
|
2021-05-03 11:14:41 +00:00
|
|
|
allowlist_externals = find
|
|
|
|
setenv =
|
|
|
|
PYTHON=coverage run --source diskimage_builder --parallel-mode
|
|
|
|
commands =
|
|
|
|
coverage erase
|
|
|
|
find . -type f -name "*.pyc" -delete
|
|
|
|
stestr run {posargs}
|
|
|
|
coverage combine
|
|
|
|
coverage html -d cover
|
|
|
|
coverage xml -o cover/coverage.xml
|
|
|
|
coverage report
|
2013-01-24 17:42:57 +00:00
|
|
|
|
2015-02-09 20:58:58 +00:00
|
|
|
[testenv:docs]
|
2020-06-05 07:51:28 +00:00
|
|
|
deps=
|
|
|
|
-c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
|
|
|
|
-r{toxinidir}/test-requirements.txt
|
|
|
|
-r{toxinidir}/doc/requirements.txt
|
2021-05-03 11:14:41 +00:00
|
|
|
allowlist_externals =
|
2019-01-04 15:25:43 +00:00
|
|
|
rm
|
|
|
|
commands =
|
|
|
|
rm -rf doc/build
|
2019-09-13 08:09:59 +00:00
|
|
|
sphinx-build -W -b html -d doc/build/doctrees doc/source doc/build/html {posargs}
|
2015-02-09 20:58:58 +00:00
|
|
|
|
2016-03-14 03:29:28 +00:00
|
|
|
[testenv:releasenotes]
|
2019-09-13 08:09:59 +00:00
|
|
|
deps = {[testenv:docs]deps}
|
2016-03-14 03:29:28 +00:00
|
|
|
commands = sphinx-build -a -W -E -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html
|
|
|
|
|
2013-06-20 05:32:55 +00:00
|
|
|
[flake8]
|
2020-02-22 23:25:38 +00:00
|
|
|
ignore = E125,E126,E127,H202,H803,W503,W504
|
2017-01-19 21:00:21 +00:00
|
|
|
exclude = .venv,.git,.tox,dist,doc/build,doc/source,*lib/python*,*egg,build,conf.py
|