2013-06-15 07:49:11 +01:00
|
|
|
[tox]
|
2016-11-08 14:15:10 +11:00
|
|
|
minversion = 2.0
|
2018-06-13 16:19:28 -04:00
|
|
|
envlist = py35,py27,pep8
|
2013-06-15 07:49:11 +01:00
|
|
|
|
|
|
|
[testenv]
|
2014-02-26 17:05:07 -08:00
|
|
|
setenv =
|
|
|
|
VIRTUAL_ENV={envdir}
|
2016-03-21 17:36:11 -04:00
|
|
|
passenv = OS_*
|
2016-11-08 14:15:10 +11:00
|
|
|
ZUUL_CACHE_DIR
|
|
|
|
REQUIREMENTS_PIP_LOCATION
|
2017-12-01 09:46:32 +01:00
|
|
|
install_command = pip install {opts} {packages}
|
|
|
|
deps =
|
|
|
|
-c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt}
|
|
|
|
-r{toxinidir}/test-requirements.txt
|
|
|
|
-r{toxinidir}/requirements.txt
|
2018-07-03 09:57:08 +07:00
|
|
|
commands = stestr run --slowest {posargs}
|
2013-06-15 07:49:11 +01:00
|
|
|
|
|
|
|
[testenv:pep8]
|
2018-06-06 15:27:01 -04:00
|
|
|
basepython = python3
|
2018-06-13 16:19:28 -04:00
|
|
|
commands =
|
|
|
|
flake8
|
|
|
|
# run security linter
|
2018-08-27 15:57:54 -04:00
|
|
|
bandit -r oslo_messaging -x tests -n5
|
2013-06-15 07:49:11 +01:00
|
|
|
|
|
|
|
[testenv:cover]
|
2018-06-06 15:27:01 -04:00
|
|
|
basepython = python3
|
2018-08-20 15:20:47 -04:00
|
|
|
setenv =
|
|
|
|
PYTHON=coverage run --source oslo_messaging --parallel-mode
|
2013-06-15 07:49:11 +01:00
|
|
|
commands =
|
2018-08-20 15:20:47 -04:00
|
|
|
stestr run --slowest {posargs}
|
|
|
|
coverage combine
|
|
|
|
coverage html -d cover
|
|
|
|
coverage report
|
2013-06-15 07:49:11 +01:00
|
|
|
|
|
|
|
[testenv:venv]
|
2018-06-06 15:27:01 -04:00
|
|
|
basepython = python3
|
2013-06-15 07:49:11 +01:00
|
|
|
commands = {posargs}
|
|
|
|
|
2014-06-26 06:32:27 +01:00
|
|
|
[testenv:docs]
|
2018-06-06 15:27:01 -04:00
|
|
|
basepython = python3
|
2017-12-11 13:49:52 -05:00
|
|
|
deps = -r{toxinidir}/doc/requirements.txt
|
2018-01-08 12:11:54 -06:00
|
|
|
commands = sphinx-build -W -b html doc/source doc/build/html
|
2014-06-26 06:32:27 +01:00
|
|
|
|
2014-10-22 23:46:48 +02:00
|
|
|
[testenv:py27-func-rabbit]
|
2018-04-13 11:02:23 -04:00
|
|
|
basepython = python2.7
|
2016-11-08 14:15:10 +11:00
|
|
|
setenv =
|
|
|
|
{[testenv]setenv}
|
|
|
|
TRANSPORT_DRIVER=rabbit
|
2018-07-03 09:57:08 +07:00
|
|
|
commands = pifpaf run rabbitmq -- stestr run --slowest {posargs:oslo_messaging.tests.functional}
|
2014-10-22 23:46:48 +02:00
|
|
|
|
2016-07-12 16:35:36 +08:00
|
|
|
[testenv:py35-func-rabbit]
|
2018-06-06 15:27:01 -04:00
|
|
|
basepython = python3.5
|
2016-11-08 14:15:10 +11:00
|
|
|
setenv =
|
|
|
|
{[testenv]setenv}
|
|
|
|
TRANSPORT_DRIVER=rabbit
|
2018-07-03 09:57:08 +07:00
|
|
|
commands = pifpaf run rabbitmq -- stestr run --slowest {posargs:oslo_messaging.tests.functional}
|
2015-10-01 18:53:17 +03:00
|
|
|
|
2016-11-30 15:37:32 +01:00
|
|
|
[testenv:py27-func-kafka]
|
2018-04-13 11:02:23 -04:00
|
|
|
basepython = python2.7
|
2016-11-30 15:37:32 +01:00
|
|
|
setenv =
|
|
|
|
{[testenv]setenv}
|
2017-12-27 11:09:02 -05:00
|
|
|
TRANSPORT_URL=kafka://127.0.0.1:9092/
|
2016-12-13 21:54:42 +01:00
|
|
|
OS_GROUP_REGEX=oslo_messaging.tests.functional
|
2018-07-03 09:57:08 +07:00
|
|
|
commands = {toxinidir}/setup-test-env-kafka.sh stestr run --slowest {posargs:oslo_messaging.tests.functional}
|
2016-11-30 15:37:32 +01:00
|
|
|
|
2014-10-22 23:46:48 +02:00
|
|
|
[testenv:py27-func-amqp1]
|
2018-04-13 11:02:23 -04:00
|
|
|
basepython = python2.7
|
2016-08-25 15:52:18 -04:00
|
|
|
setenv =
|
2016-11-08 14:15:10 +11:00
|
|
|
{[testenv]setenv}
|
2016-08-25 15:52:18 -04:00
|
|
|
TRANSPORT_URL=amqp://stackqpid:secretqpid@127.0.0.1:65123//
|
|
|
|
AMQP1_BACKEND=qpidd
|
|
|
|
ENVNAME={envname}
|
|
|
|
WORKDIR={toxworkdir}
|
2018-07-03 09:57:08 +07:00
|
|
|
commands = {toxinidir}/tools/setup-test-env-amqp1.sh stestr run --slowest {posargs:oslo_messaging.tests.functional}
|
2016-07-01 13:44:25 -04:00
|
|
|
|
2016-07-12 16:35:36 +08:00
|
|
|
[testenv:py35-func-amqp1]
|
2018-06-06 15:27:01 -04:00
|
|
|
basepython = python3.5
|
2016-08-25 15:52:18 -04:00
|
|
|
setenv =
|
2016-11-08 14:15:10 +11:00
|
|
|
{[testenv]setenv}
|
2016-08-25 15:52:18 -04:00
|
|
|
TRANSPORT_URL=amqp://stackqpid:secretqpid@127.0.0.1:65123//
|
|
|
|
AMQP1_BACKEND=qpidd
|
|
|
|
ENVNAME={envname}
|
|
|
|
WORKDIR={toxworkdir}
|
2018-07-03 09:57:08 +07:00
|
|
|
commands = {toxinidir}/tools/setup-test-env-amqp1.sh stestr run --slowest {posargs:oslo_messaging.tests.functional}
|
2016-07-12 16:35:36 +08:00
|
|
|
|
2018-04-17 11:57:48 -04:00
|
|
|
[testenv:py35-func-kafka]
|
2018-06-06 15:27:01 -04:00
|
|
|
basepython = python3.5
|
2018-04-17 11:57:48 -04:00
|
|
|
setenv =
|
|
|
|
{[testenv]setenv}
|
|
|
|
TRANSPORT_URL=kafka://127.0.0.1:9092/
|
|
|
|
OS_GROUP_REGEX=oslo_messaging.tests.functional
|
2018-07-03 09:57:08 +07:00
|
|
|
commands = {toxinidir}/setup-test-env-kafka.sh stestr run --slowest {posargs:oslo_messaging.tests.functional}
|
2018-04-17 11:57:48 -04:00
|
|
|
|
2018-06-13 16:19:28 -04:00
|
|
|
|
2015-10-26 11:01:11 +01:00
|
|
|
[testenv:bandit]
|
2018-06-13 16:19:28 -04:00
|
|
|
# NOTE(kgiusti): This is required for the integration test job of the bandit
|
|
|
|
# project. Please do not remove.
|
2018-06-06 15:27:01 -04:00
|
|
|
basepython = python3
|
2018-08-27 15:57:54 -04:00
|
|
|
commands = bandit -r oslo_messaging -x tests -n5
|
2015-10-26 11:01:11 +01:00
|
|
|
|
2013-06-15 07:49:11 +01:00
|
|
|
[flake8]
|
|
|
|
show-source = True
|
2017-06-22 11:01:23 +08:00
|
|
|
enable-extensions = H203,H106
|
2016-01-15 13:18:34 +08:00
|
|
|
ignore = H405
|
2016-02-02 11:34:01 -05:00
|
|
|
exclude = .tox,dist,doc,*.egg,build,__init__.py
|
2014-06-24 14:11:38 +02:00
|
|
|
|
|
|
|
[hacking]
|
|
|
|
import_exceptions =
|
2015-01-02 14:24:57 -05:00
|
|
|
oslo_messaging._i18n
|
2014-07-18 15:32:56 +02:00
|
|
|
six.moves
|
2015-07-13 21:09:07 +00:00
|
|
|
local-check-factory = oslo_messaging.hacking.checks.factory
|
2015-06-25 21:25:12 -04:00
|
|
|
|
2016-05-19 16:49:51 +03:00
|
|
|
[testenv:releasenotes]
|
2018-06-06 15:27:01 -04:00
|
|
|
basepython = python3
|
2016-05-19 16:49:51 +03:00
|
|
|
commands = sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html
|
2017-12-11 13:49:52 -05:00
|
|
|
deps = -r{toxinidir}/doc/requirements.txt
|
2016-12-01 08:17:18 +01:00
|
|
|
|
|
|
|
[testenv:bindep]
|
2018-06-06 15:27:01 -04:00
|
|
|
basepython = python3
|
2016-12-01 08:17:18 +01:00
|
|
|
deps = bindep
|
|
|
|
commands = bindep {posargs}
|
2018-03-22 17:35:56 -04:00
|
|
|
|
|
|
|
[testenv:lower-constraints]
|
2018-06-06 15:27:01 -04:00
|
|
|
basepython = python3
|
2018-03-22 17:35:56 -04:00
|
|
|
deps =
|
|
|
|
-c{toxinidir}/lower-constraints.txt
|
|
|
|
-r{toxinidir}/test-requirements.txt
|
|
|
|
-r{toxinidir}/requirements.txt
|