pylint fixes

a.) appease pylint on raring, as it doesn't like subprocess
    pylint: 0.26.0-1ubuntu1
    This is mentioned in comments at http://www.logilab.org/ticket/46273

b.) tests/unittests/test_util.py:
    the mountinfo lines are longer than 80 chars.
    Just disable long lines complaints for this file.
This commit is contained in:
Scott Moser
2013-03-19 09:06:31 -04:00
parent 31d56c51a4
commit ef1eaf7ca6
4 changed files with 9 additions and 6 deletions

View File

@@ -61,9 +61,10 @@ def tiny_p(cmd, capture=True):
sp = subprocess.Popen(cmd, stdout=stdout,
stderr=stderr, stdin=None)
(out, err) = sp.communicate()
if sp.returncode not in [0]:
ret = sp.returncode # pylint: disable=E1101
if ret not in [0]:
raise RuntimeError("Failed running %s [rc=%s] (%s, %s)"
% (cmd, sp.returncode, out, err))
% (cmd, ret, out, err))
return (out, err)