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

Unified Diff: tests/scm_unittest.py

Issue 3104036: Cleanup the code in gclient_utils to standardize on CheckCall nomenclature. (Closed)
Patch Set: Rewrote the patch in part as I had introduced regressions. Removed a lot of dead code Created 10 years, 4 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 | « tests/gclient_utils_test.py ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/scm_unittest.py
diff --git a/tests/scm_unittest.py b/tests/scm_unittest.py
index b5ea9ba236761e54d132e71aa72824cd466d0952..43d1c796d06c228649b96c07ea3668a568aaa75f 100755
--- a/tests/scm_unittest.py
+++ b/tests/scm_unittest.py
@@ -29,8 +29,8 @@ class BaseSCMTestCase(BaseTestCase):
def setUp(self):
BaseTestCase.setUp(self)
self.mox.StubOutWithMock(scm.gclient_utils, 'Popen')
- self.mox.StubOutWithMock(scm.gclient_utils, 'SubprocessCall')
- self.mox.StubOutWithMock(scm.gclient_utils, 'SubprocessCallAndFilter')
+ self.mox.StubOutWithMock(scm.gclient_utils, 'CheckCallAndFilter')
+ self.mox.StubOutWithMock(scm.gclient_utils, 'CheckCallAndFilterAndHeader')
class RootTestCase(BaseSCMTestCase):
@@ -129,12 +129,11 @@ from :3
def testMembersChanged(self):
self.mox.ReplayAll()
members = [
- 'COMMAND', 'AssertVersion', 'Capture', 'CaptureStatus',
+ 'AssertVersion', 'Capture', 'CaptureStatus',
'FetchUpstreamTuple',
'GenerateDiff', 'GetBranch', 'GetBranchRef', 'GetCheckoutRoot',
'GetDifferentFiles', 'GetEmail', 'GetPatchName', 'GetSVNBranch',
- 'GetUpstreamBranch', 'IsGitSvn', 'RunAndFilterOutput',
- 'ShortBranchName',
+ 'GetUpstreamBranch', 'IsGitSvn', 'ShortBranchName',
]
# If this test fails, you should add the relevant test.
self.compareMembers(scm.GIT, members)
@@ -158,12 +157,11 @@ class SVNTestCase(BaseSCMTestCase):
def testMembersChanged(self):
self.mox.ReplayAll()
members = [
- 'COMMAND', 'AssertVersion', 'Capture', 'CaptureBaseRevision',
+ 'AssertVersion', 'Capture', 'CaptureBaseRevision',
'CaptureHeadRevision', 'CaptureInfo', 'CaptureStatus',
'current_version', 'DiffItem', 'GenerateDiff',
'GetCheckoutRoot', 'GetEmail', 'GetFileProperty', 'IsMoved',
- 'IsMovedInfo', 'ReadSimpleAuth', 'Run', 'RunAndFilterOutput',
- 'RunAndGetFileList',
+ 'IsMovedInfo', 'ReadSimpleAuth', 'Run', 'RunAndGetFileList',
]
# If this test fails, you should add the relevant test.
self.compareMembers(scm.SVN, members)
@@ -315,8 +313,9 @@ class SVNTestCase(BaseSCMTestCase):
def testRun(self):
param2 = 'bleh'
- scm.gclient_utils.SubprocessCall(['svn', 'foo', 'bar'],
- cwd=param2).AndReturn(None)
+ scm.gclient_utils.CheckCallAndFilterAndHeader(
+ ['svn', 'foo', 'bar'], cwd=param2,
+ always=True).AndReturn(None)
self.mox.ReplayAll()
scm.SVN.Run(['foo', 'bar'], cwd=param2)
« no previous file with comments | « tests/gclient_utils_test.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698