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

Unified Diff: tests/gclient_test.py

Issue 391052: Group SCM-specific functions in classes to simplify generalization of the interface. (Closed)
Patch Set: One more fix Created 11 years, 1 month 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/gclient_test.py
diff --git a/tests/gclient_test.py b/tests/gclient_test.py
index dc3dff4a5c182c799b5ec9268fdea98431c8f490..e21c20ae7dceef52a27e55f185d426d8a7347954 100755
--- a/tests/gclient_test.py
+++ b/tests/gclient_test.py
@@ -22,8 +22,6 @@ import __builtin__
import StringIO
import gclient
-# Temporary due to the "from scm import *" in gclient_scm.
-import scm
from super_mox import mox, IsOneOf, SuperMoxTestBase
@@ -50,16 +48,11 @@ class GClientBaseTestCase(BaseTestCase):
self.mox.StubOutWithMock(gclient.gclient_utils, 'SubprocessCall')
self.mox.StubOutWithMock(gclient.gclient_utils, 'RemoveDirectory')
# Mock them to be sure nothing bad happens.
- self.mox.StubOutWithMock(gclient.gclient_scm, 'CaptureSVN')
- self.mox.StubOutWithMock(gclient.gclient_scm, 'CaptureSVNInfo')
- self.mox.StubOutWithMock(gclient.gclient_scm, 'CaptureSVNStatus')
- self.mox.StubOutWithMock(gclient.gclient_scm, 'RunSVN')
- self.mox.StubOutWithMock(gclient.gclient_scm, 'RunSVNAndGetFileList')
- self.mox.StubOutWithMock(scm, 'CaptureSVN')
- self.mox.StubOutWithMock(scm, 'CaptureSVNInfo')
- self.mox.StubOutWithMock(scm, 'CaptureSVNStatus')
- self.mox.StubOutWithMock(scm, 'RunSVN')
- self.mox.StubOutWithMock(scm, 'RunSVNAndGetFileList')
+ self.mox.StubOutWithMock(gclient.gclient_scm.scm.SVN, 'Capture')
+ self.mox.StubOutWithMock(gclient.gclient_scm.scm.SVN, 'CaptureInfo')
+ self.mox.StubOutWithMock(gclient.gclient_scm.scm.SVN, 'CaptureStatus')
+ self.mox.StubOutWithMock(gclient.gclient_scm.scm.SVN, 'Run')
+ self.mox.StubOutWithMock(gclient.gclient_scm.scm.SVN, 'RunAndGetFileList')
self._gclient_gclient = gclient.GClient
gclient.GClient = self.mox.CreateMockAnything()
self._scm_wrapper = gclient.gclient_scm.CreateSCM
« scm.py ('K') | « tests/gclient_scm_test.py ('k') | tests/presubmit_unittest.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698