summaryrefslogtreecommitdiffstats
path: root/conductor/tox.ini
diff options
context:
space:
mode:
Diffstat (limited to 'conductor/tox.ini')
-rw-r--r--conductor/tox.ini14
1 files changed, 11 insertions, 3 deletions
diff --git a/conductor/tox.ini b/conductor/tox.ini
index e358564..3fe867a 100644
--- a/conductor/tox.ini
+++ b/conductor/tox.ini
@@ -2,7 +2,7 @@
minversion = 1.6
skipsdist = True
#envlist = py35,py27,functional,pep8
-envlist = py3,pep8
+envlist = py3,pep8,pep8diff
[testenv]
basepython=python3
deps = -r{toxinidir}/requirements.txt
@@ -44,6 +44,11 @@ deps = hacking>=2.0.0
commands =
flake8 --exit-zero
+[testenv:pep8diff]
+deps = hacking>=2.0.0
+commands =
+ bash -c "files=$(git diff HEAD^ HEAD --relative --diff-filter=d --name-only | grep -E '(^conductor\/)'| grep -E '*\.py$'); if [[ -z $files ]]; then exit 0; else flake8 $files; fi"
+
[testenv:genconfig]
commands = oslo-config-generator --config-file=etc/conductor/conductor-config-generator.conf
@@ -55,9 +60,12 @@ setenv = PYTHONHASHSEED=0
commands = bash -x oslo_debug_helper {posargs}
[flake8]
-ignore = H301,E401,E226,E302,E41,E303,E501,E265,E125,E101,E131,E127,E306,
-exclude = .venv,.git,.tox,dist,doc,*lib/python*,*egg,build,install-guide
+select = E,H,W,F
+max-line-length = 119
+exclude = .venv,.git,.tox,dist,doc,*lib/python*,*egg,build,install-guide,*/tests/*
show-source = True
+ignore=
+per-file-ignores=
[hacking]
import_exceptions = conductor.common.i18n