1d961fcfd5
It's easy to get a false config generated using a local (non venv) environment to run generate_sample.sh, so this makes it easier to run the config generator in a venv for consistent results which should match what's done in the gate. Possibly in future we could consider removing the static conf.sample like some other projects have already done and just documenting this as the method to generate the sample. Change-Id: I92964d75e0adf73eb0935c2052adf344f15bfe95
55 lines
1.6 KiB
INI
55 lines
1.6 KiB
INI
[tox]
|
|
envlist = py26,py27,pep8
|
|
minversion = 1.6
|
|
skipsdist = True
|
|
|
|
[testenv]
|
|
# Note the hash seed is set to 0 until heat can be tested with a
|
|
# random hash seed successfully.
|
|
setenv = VIRTUAL_ENV={envdir}
|
|
PYTHONHASHSEED=0
|
|
usedevelop = True
|
|
install_command = pip install {opts} {packages}
|
|
deps = -r{toxinidir}/requirements.txt
|
|
-r{toxinidir}/test-requirements.txt
|
|
commands =
|
|
python setup.py testr --slowest --testr-args='^(?!heat_integrationtests) {posargs}'
|
|
|
|
whitelist_externals = bash
|
|
|
|
[testenv:integration]
|
|
commands =
|
|
python setup.py testr --slowest --testr-args='--concurrency=1 ^heat_integrationtests {posargs}'
|
|
|
|
[testenv:pep8]
|
|
commands =
|
|
flake8 heat bin/heat-api bin/heat-api-cfn bin/heat-api-cloudwatch bin/heat-engine bin/heat-manage contrib heat_integrationtests
|
|
{toxinidir}/tools/config/check_uptodate.sh
|
|
# Check that .po and .pot files are valid:
|
|
bash -c "find heat -type f -regex '.*\.pot?' -print0|xargs -0 -n 1 msgfmt --check-format -o /dev/null"
|
|
|
|
[testenv:venv]
|
|
commands = {posargs}
|
|
|
|
[testenv:cover]
|
|
commands =
|
|
python setup.py testr --coverage --testr-args='{posargs}'
|
|
|
|
[testenv:docs]
|
|
deps = -r{toxinidir}/requirements.txt
|
|
-r{toxinidir}/test-requirements.txt
|
|
sphinxcontrib-httpdomain
|
|
commands = python setup.py build_sphinx
|
|
|
|
[testenv:genconfig]
|
|
commands =
|
|
bash tools/config/generate_sample.sh -b . -p heat -o etc/heat
|
|
|
|
[flake8]
|
|
# H302 import only modules.'bla..' does not import a module
|
|
# H404 multi line docstring should start with a summary
|
|
# H803 no full stop at the end of the commit message
|
|
ignore = H302,H404,H803
|
|
show-source = true
|
|
exclude=.venv,.git,.tox,dist,*openstack/common*,*lib/python*,*egg,tools,build
|