dfd4c1b29e
This patch enables tox to test both old architecture and new architecture. If you'd like to test with new architecture, execute following command. $ tox -enew_arch Change-Id: I28a137b73fcd8f56ecdeedfc20274f7b37bab620
71 lines
1.8 KiB
INI
71 lines
1.8 KiB
INI
[tox]
|
|
minversion = 1.6
|
|
skipsdist = True
|
|
envlist = py34,py27,pep8,new_arch
|
|
|
|
[testenv]
|
|
usedevelop = True
|
|
|
|
install_command = pip install -U {opts} {packages}
|
|
whitelist_externals = find
|
|
setenv =
|
|
VIRTUAL_ENV={envdir}
|
|
LANG=en_US.UTF-8
|
|
LANGUAGE=en_US
|
|
LC_ALL=en_US.utf-8
|
|
deps = -r{toxinidir}/requirements.txt
|
|
-r{toxinidir}/test-requirements.txt
|
|
commands =
|
|
{toxinidir}/tools/check_dot_testr_conf.sh .testr.conf.old
|
|
find . -type f -name "*.pyc" -delete
|
|
python setup.py testr --slowest --testr-args='{posargs}'
|
|
|
|
[testenv:new_arch]
|
|
usedevelop = True
|
|
|
|
install_command = pip install -U {opts} {packages}
|
|
whitelist_externals = find
|
|
setenv =
|
|
VIRTUAL_ENV={envdir}
|
|
LANG=en_US.UTF-8
|
|
LANGUAGE=en_US
|
|
LC_ALL=en_US.utf-8
|
|
deps = -r{toxinidir}/requirements.txt
|
|
-r{toxinidir}/test-requirements.txt
|
|
commands =
|
|
{toxinidir}/tools/check_dot_testr_conf.sh .testr.conf.new
|
|
find . -type f -name "*.pyc" -delete
|
|
python setup.py testr --slowest --testr-args='{posargs}'
|
|
|
|
[testenv:pep8]
|
|
usedevelop = False
|
|
deps =
|
|
commands = {toxinidir}/tools/pip-install-single-req.sh test-requirements.txt hacking
|
|
flake8
|
|
|
|
[testenv:venv]
|
|
commands = {posargs}
|
|
|
|
[testenv:cover]
|
|
commands = python setup.py testr --coverage --testr-args='{posargs}'
|
|
|
|
[testenv:bench]
|
|
setenv =
|
|
TEST_BENCHMARK=true
|
|
VIRTUAL_ENV={envdir}
|
|
LANG=en_US.UTF-8
|
|
LANGUAGE=en_US
|
|
LC_ALL=en_US.utf-8
|
|
commands = python setup.py testr --no-parallel --testr-args='test_benchmark {posargs}'
|
|
testr slowest --all
|
|
|
|
[flake8]
|
|
show-source = True
|
|
builtins = _
|
|
exclude=.venv,.git,.tox,dist,doc,*openstack/common*,*lib/python*,*egg,build,*thirdparty/*,CongressLexer.py,CongressParser.py,contrib/*
|
|
|
|
[testenv:genconfig]
|
|
deps =
|
|
commands = {toxinidir}/tools/pip-install-single-req.sh requirements.txt oslo.config
|
|
oslo-config-generator --config-file=etc/congress-config-generator.conf
|