deb-heat/tox.ini
Steve Baker f3b8e93238 Support classes for heat integration tests
These support classes started as a forklift of the classes needed
to run tempest scenario orchestration tests.

The original tempest code has been pared back to provide the
small subset required by heat integration tests. From this point on
these support classes can evolve to the specific needs of the
integration tests.

There is some unused code (especially in remote_client) which has
been left in as it may become useful in the future, and is already
extremely well reviewed and tested from being developed for tempest.

The script heat_integrationtests/generate_sample.sh will generate
an up-to-date heat_integrationtests/heat_integrationtests.conf.sample
file which can be copied to
heat_integrationtests/heat_integrationtests.conf
to override default configuration values. A local ConfigOpts is created
for each test to avoid any potential interaction with heat's
global CONF. Configuration options for credentials default to
being sourced from the environment.

The default tox testenv now excludes tests in heat_integrationtests.
A new testenv called "integration" will only run tests in
heat_integrationtests.

Integration tests will fail if preconditions are not met, including
a keystone endpoint, credentials and glance containing the expected
named image.

Devstack gate hooks have been moved to heat_integrationtests now that
the name of the package has been decided.

Change-Id: I174429c16bb606c5c325ee8b62c6e600ea77a6e6
Partial-Blueprint: functional-tests
2014-09-24 09:02:20 +12:00

52 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
[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
builtins = _
exclude=.venv,.git,.tox,dist,*openstack/common*,*lib/python*,*egg,tools,build