Files
deb-python-fuelclient/tox.ini
Roman Prykhodchenko 4dffff9660 Support separate jUnit files for environments
Otherwise they get overwritten by each other.

Change-Id: Ib216a0eb302a62acbb5045cadb3a0c31074c40c2
Related-bug: #1476808
2015-08-19 16:50:25 +02:00

74 lines
2.2 KiB
INI

[tox]
minversion = 2.1
skipsdist = True
envlist = py26,py27,pep8,functional,cleanup
[testenv]
usedevelop = True
install_command = pip install --allow-external -U {opts} {packages}
whitelist_externals = bash
setenv = VIRTUAL_ENV={envdir}
ARTIFACTS={toxinidir}/{env:ARTIFACTS:test_run}
FUELCLIENT_JUNIT={env:FUELCLIENT_JUNIT:fuelclient}-{envname}.xml
FUELCLIENT_CUSTOM_SETTINGS={toxinidir}/{env:ARTIFACTS:test_run}/fuel_client_config.yaml
# Functional env settings
FUEL_WEB_CLONE={env:FUEL_WEB_CLONE:yes}
FUEL_WEB_REPO={env:FUEL_WEB_REPO:https://github.com/stackforge/fuel-web.git}
FUEL_WEB_ROOT={env:FUEL_WEB_ROOT:/tmp/fuel_web}
FETCH_REPO={env:FETCH_REPO:}
FETCH_REFSPEC={env:FETCH_REFSPEC:}
FUEL_COMMIT={env:FUEL_COMMIT:master}
NAILGUN_ROOT={env:FUEL_WEB_ROOT:/tmp/fuel_web}/nailgun
# Nailgun server parameters
NAILGUN_PORT={env:NAILGUN_PORT:8003}
NAILGUN_CHECK_PATH={env:NAILGUN_CHECK_PATH:/api/version}
NAILGUN_START_MAX_WAIT_TIME={env:NAILGUN_START_MAX_WAIT_TIME:20}
TEST_NAILGUN_DB={env:TEST_NAILGUN_DB:nailgun}
deps = -r{toxinidir}/requirements.txt
-r{toxinidir}/test-requirements.txt
commands =
py.test -vv --junit-xml $FUELCLIENT_JUNIT {posargs:fuelclient/tests/unit}
[testenv:functional]
commands =
bash {toxinidir}/tools/cleanup.sh
bash {toxinidir}/tools/prepare_nailgun.sh
py.test -vv --junit-xml $FUELCLIENT_JUNIT {posargs:fuelclient/tests/functional}
[testenv:cleanup]
commands =
bash {toxinidir}/tools/cleanup.sh
bash -c "find {toxinidir} -name \"*.pyc\" -delete"
[tox:jenkins]
downloadcache = ~/cache/pip
[testenv:pep8]
deps = hacking==0.7
usedevelop = False
commands =
flake8 {posargs:fuelclient}
[testenv:cover]
commands =
py.test -vv --junit-xml $FUELCLIENT_JUNIT --cov=fuelclient {posargs:fuelclient/tests/unit}
[testenv:venv]
commands = {posargs:}
[testenv:devenv]
envdir = devenv
usedevelop = True
[flake8]
ignore = H234,H302,H802
exclude = .venv,.git,.tox,dist,doc,*lib/python*,*egg,build,tools,__init__.py,docs
show-pep8 = True
show-source = True
count = True
[hacking]
import_exceptions = testtools.matchers