anchor/tox.ini
Tim Kelsey 7954b8a742 Tox now also runs PEP8 on test code
Change-Id: I3bc67522d303ab2e4fbe960c05bf536e72c5ffe6
2015-02-17 21:31:56 +00:00

43 lines
1.0 KiB
INI

[tox]
minversion = 1.6
envlist = pypy,py27,pep8
skipsdist = True
[testenv]
usedevelop = True
install_command = pip install -U {opts} {packages}
setenv =
VIRTUAL_ENV={envdir}
deps = -r{toxinidir}/requirements.txt
-r{toxinidir}/test-requirements.txt
commands =
python setup.py testr --coverage --slowest --testr-args='{posargs}'
coverage combine
coverage report -m
[testenv:pep8]
commands = flake8 {posargs} anchor
flake8 {posargs} tests
[testenv:venv]
commands = {posargs}
[testenv:cover]
commands =
python setup.py testr --coverage --testr-args='{posargs}'
coverage combine
coverage xml
[flake8]
# E123, E125 skipped as they are invalid PEP-8.
# H303 no wild card imports
# F403 unable to detect undefined names
# H104 file contains nothing but comments
# H302 import only modules
# H301,H305,H405,H404,H306,E226,H904,H307,F401
show-source = True
ignore = E123,E125,H303,F403,H104,H302,E501,H307,H304
builtins = _
exclude=.venv,.git,.tox,dist,doc,*openstack/common*,*lib/python*,*egg,build