2012-01-07 19:34:41 -08:00
|
|
|
[tox]
|
2013-08-15 14:36:40 -03:00
|
|
|
minversion = 1.6
|
2013-06-01 16:45:45 -05:00
|
|
|
envlist = py26,py27,py33,pep8
|
2013-08-15 14:36:40 -03:00
|
|
|
skipsdist = True
|
2012-01-07 19:34:41 -08:00
|
|
|
|
|
|
|
[testenv]
|
2013-02-07 21:39:31 -08:00
|
|
|
sitepackages = True
|
2013-08-15 14:36:40 -03:00
|
|
|
usedevelop = True
|
2014-03-25 12:14:04 -07:00
|
|
|
install_command = pip install -U --force-reinstall {opts} {packages}
|
2012-02-25 12:25:56 -08:00
|
|
|
setenv = VIRTUAL_ENV={envdir}
|
2013-08-15 14:36:40 -03:00
|
|
|
deps = -r{toxinidir}/requirements.txt
|
2013-05-22 20:12:08 +00:00
|
|
|
-r{toxinidir}/test-requirements.txt
|
2013-03-06 16:00:37 -05:00
|
|
|
commands =
|
2013-12-17 13:52:45 +02:00
|
|
|
python -m nova.openstack.common.lockutils python setup.py test --slowest --testr-args='{posargs}'
|
2012-01-07 19:34:41 -08:00
|
|
|
|
2012-05-05 13:51:32 -07:00
|
|
|
[tox:jenkins]
|
2012-09-26 17:09:10 -07:00
|
|
|
sitepackages = True
|
2012-01-07 19:34:41 -08:00
|
|
|
downloadcache = ~/cache/pip
|
|
|
|
|
|
|
|
[testenv:pep8]
|
2013-05-17 12:54:12 -07:00
|
|
|
sitepackages = False
|
|
|
|
commands =
|
2013-05-28 08:12:58 +03:00
|
|
|
flake8 {posargs}
|
2012-01-07 19:34:41 -08:00
|
|
|
|
2014-03-19 10:56:49 -07:00
|
|
|
[testenv:genconfig]
|
|
|
|
sitepackages = False
|
|
|
|
commands =
|
|
|
|
bash tools/config/generate_sample.sh -b . -p nova -o etc/nova
|
|
|
|
|
2012-08-15 18:26:41 -04:00
|
|
|
[testenv:pylint]
|
|
|
|
setenv = VIRTUAL_ENV={envdir}
|
|
|
|
commands = bash tools/lintstack.sh
|
|
|
|
|
2012-05-25 15:27:03 -04:00
|
|
|
[testenv:cover]
|
2013-01-15 06:40:47 +00:00
|
|
|
# Also do not run test_coverage_ext tests while gathering coverage as those
|
|
|
|
# tests conflict with coverage.
|
2013-03-06 16:00:37 -05:00
|
|
|
setenv = VIRTUAL_ENV={envdir}
|
2013-01-15 06:40:47 +00:00
|
|
|
commands =
|
|
|
|
python setup.py testr --coverage \
|
2013-01-21 19:05:51 -08:00
|
|
|
--testr-args='^(?!.*test.*coverage).*$'
|
2012-01-07 19:34:41 -08:00
|
|
|
|
|
|
|
[testenv:venv]
|
|
|
|
commands = {posargs}
|
2013-05-17 12:54:12 -07:00
|
|
|
|
2014-03-11 09:40:08 -07:00
|
|
|
[testenv:py27local]
|
|
|
|
sitepackages = False
|
|
|
|
|
2013-05-17 12:54:12 -07:00
|
|
|
[flake8]
|
2013-07-25 21:47:39 -04:00
|
|
|
# E712 is ignored on purpose, since it is normal to use 'column == true'
|
|
|
|
# in sqlalchemy.
|
2013-10-24 12:54:17 +08:00
|
|
|
# H803 skipped on purpose per list discussion.
|
2013-11-20 22:35:08 +10:30
|
|
|
# E125 is deliberately excluded. See https://github.com/jcrocholl/pep8/issues/126
|
2013-12-11 19:18:53 +01:00
|
|
|
# The rest of the ignores are TODOs
|
|
|
|
|
2014-02-24 10:41:36 +04:00
|
|
|
ignore = E121,E122,E123,E124,E125,E126,E127,E128,E711,E712,F811,F841,H803
|
2013-09-17 16:44:59 +00:00
|
|
|
exclude = .venv,.git,.tox,dist,doc,*openstack/common*,*lib/python*,*egg,build,tools
|
2013-05-17 12:54:12 -07:00
|
|
|
|
|
|
|
[hacking]
|
|
|
|
local-check-factory = nova.hacking.checks.factory
|
2014-04-18 11:25:38 -07:00
|
|
|
import_exceptions = nova.openstack.common.gettextutils
|