2011-10-25 16:50:08 -07:00
|
|
|
[tox]
|
2022-05-22 22:26:05 +09:00
|
|
|
minversion = 3.18.0
|
2013-11-14 21:00:54 -06:00
|
|
|
skipsdist = True
|
2020-04-24 10:25:55 -05:00
|
|
|
envlist = py38,pep8,releasenotes
|
2019-12-15 18:11:36 +05:30
|
|
|
ignore_basepython_conflict = True
|
2011-10-25 16:50:08 -07:00
|
|
|
|
|
|
|
[testenv]
|
2013-11-14 21:00:54 -06:00
|
|
|
usedevelop = True
|
2020-04-10 23:04:32 +02:00
|
|
|
setenv = OS_STDOUT_NOCAPTURE=False
|
2012-12-25 00:02:54 -06:00
|
|
|
OS_STDERR_NOCAPTURE=False
|
|
|
|
|
2017-12-02 09:28:03 +01:00
|
|
|
deps =
|
2020-12-24 14:13:18 +08:00
|
|
|
-c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
|
2017-12-02 09:28:03 +01:00
|
|
|
-r{toxinidir}/requirements.txt
|
2013-05-24 18:37:26 -05:00
|
|
|
-r{toxinidir}/test-requirements.txt
|
2015-12-02 12:52:30 +09:00
|
|
|
commands = find . -type f -name "*.pyc" -delete
|
2018-07-10 13:38:09 +07:00
|
|
|
stestr run --slowest {posargs}
|
2022-05-22 22:26:05 +09:00
|
|
|
allowlist_externals = find
|
2019-12-15 18:11:36 +05:30
|
|
|
basepython = python3
|
2012-06-14 14:14:25 -04:00
|
|
|
|
2016-02-10 21:20:37 +01:00
|
|
|
[testenv:pep8]
|
2013-05-10 18:19:59 -04:00
|
|
|
commands =
|
|
|
|
flake8
|
2016-03-11 15:55:06 -06:00
|
|
|
bandit -r keystoneclient -x tests -n5
|
2016-01-18 21:54:29 +01:00
|
|
|
|
2016-02-17 14:11:19 -08:00
|
|
|
[testenv:bandit]
|
|
|
|
# NOTE(browne): This is required for the integration test job of the bandit
|
|
|
|
# project. Please do not remove.
|
2016-03-11 15:55:06 -06:00
|
|
|
commands = bandit -r keystoneclient -x tests -n5
|
2016-02-17 14:11:19 -08:00
|
|
|
|
2012-03-21 10:34:46 -04:00
|
|
|
[testenv:venv]
|
|
|
|
commands = {posargs}
|
2012-12-25 00:02:54 -06:00
|
|
|
|
|
|
|
[testenv:cover]
|
2018-07-10 13:38:09 +07:00
|
|
|
setenv =
|
|
|
|
PYTHON=coverage run --source keystoneclient --parallel-mode
|
|
|
|
commands =
|
2018-10-09 13:54:35 +00:00
|
|
|
stestr run {posargs}
|
2018-07-10 13:38:09 +07:00
|
|
|
coverage combine
|
|
|
|
coverage html -d cover
|
|
|
|
coverage xml -o cover/coverage.xml
|
|
|
|
coverage report
|
2012-12-25 00:02:54 -06:00
|
|
|
|
2014-01-06 15:16:52 -06:00
|
|
|
[testenv:debug]
|
2014-09-09 10:14:54 -04:00
|
|
|
commands = oslo_debug_helper -t keystoneclient/tests {posargs}
|
2014-01-06 15:16:52 -06:00
|
|
|
|
2015-02-13 11:16:03 +11:00
|
|
|
[testenv:functional]
|
2016-12-21 12:58:12 +11:00
|
|
|
setenv = {[testenv]setenv}
|
|
|
|
OS_TEST_PATH=./keystoneclient/tests/functional
|
2015-05-13 19:31:33 -05:00
|
|
|
passenv = OS_*
|
2015-02-13 11:16:03 +11:00
|
|
|
|
2013-05-10 18:19:59 -04:00
|
|
|
[flake8]
|
2015-10-01 16:59:36 +00:00
|
|
|
# D100: Missing docstring in public module
|
|
|
|
# D101: Missing docstring in public class
|
|
|
|
# D102: Missing docstring in public method
|
|
|
|
# D103: Missing docstring in public function
|
|
|
|
# D104: Missing docstring in public package
|
2023-02-17 09:06:59 -06:00
|
|
|
# D107: Missing docstring in __init__
|
2016-06-03 08:53:12 -05:00
|
|
|
# D203: 1 blank line required before class docstring (deprecated in pep257)
|
2023-02-17 09:06:59 -06:00
|
|
|
# D401 First line should be in imperative mood; try rephrasing
|
2020-03-31 12:11:21 +02:00
|
|
|
# W504 line break after binary operator
|
2023-02-17 09:06:59 -06:00
|
|
|
ignore = D100,D101,D102,D103,D104,D107,D203,D401,W504
|
2013-05-10 18:19:59 -04:00
|
|
|
show-source = True
|
2016-05-11 13:52:03 +08:00
|
|
|
exclude = .venv,.tox,dist,doc,*egg,build
|
2014-02-10 18:47:37 -06:00
|
|
|
|
|
|
|
[testenv:docs]
|
2020-04-15 10:40:01 +02:00
|
|
|
commands = sphinx-build -W -b html doc/source doc/build/html
|
2023-02-17 09:06:59 -06:00
|
|
|
deps =
|
|
|
|
-r{toxinidir}/doc/requirements.txt
|
|
|
|
-r{toxinidir}/requirements.txt
|
2014-02-10 18:47:37 -06:00
|
|
|
|
2019-08-30 10:37:06 +05:30
|
|
|
[testenv:pdf-docs]
|
|
|
|
deps = {[testenv:docs]deps}
|
2022-05-22 22:26:05 +09:00
|
|
|
allowlist_externals =
|
2019-08-30 10:37:06 +05:30
|
|
|
make
|
|
|
|
rm
|
|
|
|
commands =
|
|
|
|
rm -rf doc/build/pdf
|
|
|
|
sphinx-build -W -b latex doc/source doc/build/pdf
|
|
|
|
make -C doc/build/pdf
|
|
|
|
|
2015-11-29 17:25:13 -05:00
|
|
|
[testenv:releasenotes]
|
|
|
|
commands = sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html
|
2017-12-19 14:20:14 +08:00
|
|
|
deps = -r{toxinidir}/doc/requirements.txt
|
2015-11-29 17:25:13 -05:00
|
|
|
|
2014-10-27 10:54:48 -05:00
|
|
|
[hacking]
|
|
|
|
import_exceptions =
|
|
|
|
keystoneclient.i18n
|
2016-06-28 11:46:50 +02:00
|
|
|
|
|
|
|
[testenv:bindep]
|
|
|
|
# Do not install any requirements. We want this to be fast and work even if
|
|
|
|
# system dependencies are missing, since it's used to tell you what system
|
|
|
|
# dependencies are missing! This also means that bindep must be installed
|
|
|
|
# separately, outside of the requirements files.
|
|
|
|
deps = bindep
|
|
|
|
commands = bindep test
|
2018-03-22 17:50:49 -04:00
|
|
|
|