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

Unified Diff: tests/presubmit_unittest.py

Issue 955993006: Handle KeyboardInterrupt consistently in python scripts (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/depot_tools
Patch Set: tweek test expectations Created 5 years, 10 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
Index: tests/presubmit_unittest.py
diff --git a/tests/presubmit_unittest.py b/tests/presubmit_unittest.py
index 4be5daffeb0653989cc74564c29688d94bf8dcf8..84d9adda2699e451280dbb9067a16fc34bb73415 100755
--- a/tests/presubmit_unittest.py
+++ b/tests/presubmit_unittest.py
@@ -167,7 +167,7 @@ class PresubmitUnittest(PresubmitTestsBase):
members = [
'AffectedFile', 'Change', 'DoGetTrySlaves', 'DoPresubmitChecks',
'GetTrySlavesExecuter', 'GitAffectedFile', 'CallCommand', 'CommandData',
- 'GitChange', 'InputApi', 'ListRelevantPresubmitFiles', 'Main',
+ 'GitChange', 'InputApi', 'ListRelevantPresubmitFiles', 'main',
'NonexistantCannedCheckFilter', 'OutputApi', 'ParseFiles',
'PresubmitFailure', 'PresubmitExecuter', 'PresubmitOutput', 'ScanSubDirs',
'SvnAffectedFile', 'SvnChange', 'cPickle', 'cpplint', 'cStringIO',
@@ -1152,7 +1152,7 @@ def CheckChangeOnCommit(input_api, output_api):
self.assertEquals(
True,
- presubmit.Main(['--root', self.fake_root_dir, 'random_file.txt']))
+ presubmit.main(['--root', self.fake_root_dir, 'random_file.txt']))
def testMainUnversionedFail(self):
# OptParser calls presubmit.os.path.exists and is a pain when mocked.
@@ -1170,7 +1170,7 @@ def CheckChangeOnCommit(input_api, output_api):
self.mox.ReplayAll()
try:
- presubmit.Main(['--root', self.fake_root_dir])
+ presubmit.main(['--root', self.fake_root_dir])
self.fail()
except SystemExit, e:
self.assertEquals(2, e.code)
« clang_format.py ('K') | « roll_dep.py ('k') | upload_to_google_storage.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698