| Index: PRESUBMIT_test_mocks.py
|
| diff --git a/PRESUBMIT_test_mocks.py b/PRESUBMIT_test_mocks.py
|
| index 772f405725be0f575c193ad0ecac46d93d973d06..37b0159276df974fcb9cef44f39fdd4473913273 100644
|
| --- a/PRESUBMIT_test_mocks.py
|
| +++ b/PRESUBMIT_test_mocks.py
|
| @@ -99,6 +99,10 @@ class MockFile(object):
|
| self._new_contents = new_contents
|
| self._changed_contents = [(i + 1, l) for i, l in enumerate(new_contents)]
|
| self._action = action
|
| + self._scm_diff = "--- /dev/null\n+++ %s\n@@ -0,0 +1,%d @@\n" % (local_path,
|
| + len(new_contents))
|
| + for l in new_contents:
|
| + self._scm_diff += "+%s\n" % l
|
|
|
| def Action(self):
|
| return self._action
|
| @@ -115,6 +119,9 @@ class MockFile(object):
|
| def AbsoluteLocalPath(self):
|
| return self._local_path
|
|
|
| + def GenerateScmDiff(self):
|
| + return self._scm_diff;
|
| +
|
| def rfind(self, p):
|
| """os.path.basename is called on MockFile so we need an rfind method."""
|
| return self._local_path.rfind(p)
|
|
|