Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(31)

Unified Diff: tests/subprocess2_test.py

Issue 9172002: Fix variable aliasing. Fixes pylint W0623. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/depot_tools
Patch Set: Created 8 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/subprocess2_test.py
diff --git a/tests/subprocess2_test.py b/tests/subprocess2_test.py
index d9321797b0398396813184601aaed800198710d4..e1074f0f3d23e5cd72cfce36953ea772e6feaa1b 100755
--- a/tests/subprocess2_test.py
+++ b/tests/subprocess2_test.py
@@ -253,8 +253,8 @@ class RegressionTest(BaseTestCase):
subp.check_output(
e + ['--fail', '--stdout'], universal_newlines=un)
self.fail()
- except subp.CalledProcessError, e:
- self._check_exception(subp, e, c('A\nBB\nCCC\n'), None, 64)
+ except subp.CalledProcessError, exception:
+ self._check_exception(subp, exception, c('A\nBB\nCCC\n'), None, 64)
self._run_test(fn)
def test_check_output_throw_no_stderr(self):
@@ -265,8 +265,8 @@ class RegressionTest(BaseTestCase):
subp.check_output(
e + ['--fail', '--stderr'], universal_newlines=un)
self.fail()
- except subp.CalledProcessError, e:
- self._check_exception(subp, e, c(''), None, 64)
+ except subp.CalledProcessError, exception:
+ self._check_exception(subp, exception, c(''), None, 64)
self._run_test(fn)
def test_check_output_throw_stderr(self):
@@ -279,8 +279,8 @@ class RegressionTest(BaseTestCase):
stderr=subp.PIPE,
universal_newlines=un)
self.fail()
- except subp.CalledProcessError, e:
- self._check_exception(subp, e, '', c('a\nbb\nccc\n'), 64)
+ except subp.CalledProcessError, exception:
+ self._check_exception(subp, exception, '', c('a\nbb\nccc\n'), 64)
self._run_test(fn)
def test_check_output_throw_stderr_stdout(self):
@@ -293,8 +293,8 @@ class RegressionTest(BaseTestCase):
stderr=subp.STDOUT,
universal_newlines=un)
self.fail()
- except subp.CalledProcessError, e:
- self._check_exception(subp, e, c('a\nbb\nccc\n'), None, 64)
+ except subp.CalledProcessError, exception:
+ self._check_exception(subp, exception, c('a\nbb\nccc\n'), None, 64)
self._run_test(fn)
def test_check_call_throw(self):
@@ -302,8 +302,8 @@ class RegressionTest(BaseTestCase):
try:
subp.check_call(self.exe + ['--fail', '--stderr'])
self.fail()
- except subp.CalledProcessError, e:
- self._check_exception(subp, e, None, None, 64)
+ except subp.CalledProcessError, exception:
+ self._check_exception(subp, exception, None, None, 64)
def test_redirect_stderr_to_stdout_pipe(self):
def fn(c, e, un, subp):
@@ -503,8 +503,8 @@ class S2Test(BaseTestCase):
stderr=stderr.append,
universal_newlines=un)
self.fail()
- except subprocess2.CalledProcessError, e:
- self._check_exception(e, '', None, 64)
+ except subprocess2.CalledProcessError, exception:
+ self._check_exception(exception, '', None, 64)
self.assertEquals(c('a\nbb\nccc\n'), ''.join(stderr))
self._run_test(fn)
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698