Migrate to flake8.
Fixes bug 1172444. Change-Id: I0d8faa0819738456a28aaf5cc859f510a2b3ed68
This commit is contained in:
parent
1a0b7b0a64
commit
9d4db6f740
@ -102,13 +102,8 @@ function copy_subunit_log {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function run_pep8 {
|
function run_pep8 {
|
||||||
echo "Running pep8 ..."
|
echo "Running flake8 ..."
|
||||||
srcfiles="--exclude=.venv,.git,.tox,dist,doc,*openstack/common*,*lib/python*"
|
${wrapper} flake8
|
||||||
srcfiles+=",*egg,build ."
|
|
||||||
# Just run PEP8 in current environment
|
|
||||||
#
|
|
||||||
ignore="--ignore=E12,E711,E721,E712"
|
|
||||||
${wrapper} pep8 ${ignore} --show-source ${srcfiles}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
TESTRTESTS="testr run --parallel $testropts"
|
TESTRTESTS="testr run --parallel $testropts"
|
||||||
|
@ -1,11 +1,16 @@
|
|||||||
distribute>=0.6.24
|
distribute>=0.6.24
|
||||||
|
|
||||||
|
# Install bounded pep8/pyflakes first, then let flake8 install
|
||||||
|
pep8==1.4.5
|
||||||
|
pyflakes==0.7.2
|
||||||
|
flake8==2.0
|
||||||
|
hacking>=0.5.3,<0.6
|
||||||
|
|
||||||
coverage
|
coverage
|
||||||
discover
|
discover
|
||||||
fixtures>=0.3.12
|
fixtures>=0.3.12
|
||||||
keyring
|
keyring
|
||||||
mock
|
mock
|
||||||
pep8==1.3.3
|
|
||||||
sphinx>=1.1.2
|
sphinx>=1.1.2
|
||||||
testrepository>=0.0.13
|
testrepository>=0.0.13
|
||||||
testtools>=0.9.26
|
testtools>=0.9.26
|
||||||
|
10
tox.ini
10
tox.ini
@ -12,10 +12,7 @@ deps = -r{toxinidir}/tools/pip-requires
|
|||||||
commands = python setup.py testr --testr-args='{posargs}'
|
commands = python setup.py testr --testr-args='{posargs}'
|
||||||
|
|
||||||
[testenv:pep8]
|
[testenv:pep8]
|
||||||
deps = pep8==1.3.3
|
commands = flake8
|
||||||
commands =
|
|
||||||
pep8 --ignore=E12,E711,E721,E712 --show-source \
|
|
||||||
--exclude=.venv,.git,.tox,dist,doc,*openstack/common*,*lib/python*,*egg,build .
|
|
||||||
|
|
||||||
[testenv:venv]
|
[testenv:venv]
|
||||||
commands = {posargs}
|
commands = {posargs}
|
||||||
@ -25,3 +22,8 @@ commands = python setup.py testr --coverage --testr-args='{posargs}'
|
|||||||
|
|
||||||
[tox:jenkins]
|
[tox:jenkins]
|
||||||
downloadcache = ~/cache/pip
|
downloadcache = ~/cache/pip
|
||||||
|
|
||||||
|
[flake8]
|
||||||
|
ignore = E12,E711,E721,E712,F,H
|
||||||
|
show-source = True
|
||||||
|
exclude=.venv,.git,.tox,dist,doc,*openstack/common*,*lib/python*,*egg,build
|
||||||
|
Loading…
x
Reference in New Issue
Block a user