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

Unified Diff: tests/presubmit_unittest.py

Issue 242140: Git support in presubmit tests.... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/depot_tools/
Patch Set: '' Created 11 years, 2 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 | « presubmit_support.py ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/presubmit_unittest.py
===================================================================
--- tests/presubmit_unittest.py (revision 27963)
+++ tests/presubmit_unittest.py (working copy)
@@ -53,12 +53,16 @@
self.mox.StubOutWithMock(presubmit, 'random')
self.mox.StubOutWithMock(presubmit, 'sys')
presubmit._ASKED_FOR_FEEDBACK = False
+ presubmit.os.path.commonprefix = os_path_commonprefix
+ self.fake_root_dir = self.RootDir()
# Special mocks.
def MockAbsPath(f):
return f
+ def MockChdir(f):
+ return None
presubmit.os.path.abspath = MockAbsPath
- presubmit.os.path.commonprefix = os_path_commonprefix
- self.fake_root_dir = self.RootDir()
+ presubmit.os.getcwd = self.RootDir
+ presubmit.os.chdir = MockChdir
self.mox.StubOutWithMock(presubmit.gclient_scm, 'CaptureSVNInfo')
self.mox.StubOutWithMock(presubmit.gcl, 'GetSVNFileProperty')
self.mox.StubOutWithMock(presubmit.gcl, 'ReadFile')
« no previous file with comments | « presubmit_support.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698