d0ddc629f3
To solve the problem of "db type could not be determined" on py34 we have to run first the py3x env to, then, run py27. This patch puts py3x first on the tox.ini list of envs to avoid this problem to happen. Change-Id: Iae20a766f77ac5b09e1d98569c111888dfb18c12 Closes-bug: #1489059
51 lines
1.2 KiB
INI
51 lines
1.2 KiB
INI
[tox]
|
|
minversion = 1.6
|
|
skipsdist = True
|
|
envlist = py33,py27,pep8
|
|
|
|
[testenv]
|
|
setenv = VIRTUAL_ENV={envdir}
|
|
usedevelop = True
|
|
install_command = pip install -U {opts} {packages}
|
|
deps = -r{toxinidir}/requirements.txt
|
|
-r{toxinidir}/test-requirements.txt
|
|
whitelist_externals = find
|
|
commands =
|
|
find . -type f -name "*.pyc" -delete
|
|
python setup.py testr --testr-args='{posargs}'
|
|
|
|
[testenv:cover]
|
|
setenv = NOSE_WITH_COVERAGE=1
|
|
commands =
|
|
python setup.py testr --coverage \
|
|
--testr-args='^(?!.*test.*coverage).*$'
|
|
|
|
[testenv:pep8]
|
|
commands =
|
|
flake8 monasca_api
|
|
|
|
[testenv:genconfig]
|
|
|
|
[testenv:docs]
|
|
commands = python setup.py build_sphinx
|
|
|
|
[testenv:venv]
|
|
commands = {posargs}
|
|
|
|
[flake8]
|
|
# TODO: ignored checks should be enabled in the future
|
|
# H201 no 'except:' at least use 'except Exception:'
|
|
# H302 import only modules
|
|
# H305 imports not grouped correctly
|
|
# H307 like imports should be grouped together
|
|
# H405 multi line docstring summary not separated with an empty line
|
|
# H904 Wrap long lines in parentheses instead of a backslash
|
|
ignore = F821,H201,H302,H305,H307,H405,H904
|
|
max-complexity = 50
|
|
max-line-length = 120
|
|
builtins = _
|
|
exclude=.venv,.git,.tox,dist,doc,*lib/python*,*egg,tools,build
|
|
show-source = True
|
|
|
|
[hacking]
|