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

Unified Diff: Tools/Scripts/webkitpy/common/checkout/scm/svn.py

Issue 397383002: Fix webkitpy scm_unittests so that they pass again. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: patch for review Created 6 years, 5 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 | « Tools/Scripts/webkitpy/common/checkout/scm/scm_unittest.py ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Tools/Scripts/webkitpy/common/checkout/scm/svn.py
diff --git a/Tools/Scripts/webkitpy/common/checkout/scm/svn.py b/Tools/Scripts/webkitpy/common/checkout/scm/svn.py
index 54f2fa8e750a76a46de89801ae281ce08c947191..4236d0931b5fbe34dcf6782ee2d1ee291bc27305 100644
--- a/Tools/Scripts/webkitpy/common/checkout/scm/svn.py
+++ b/Tools/Scripts/webkitpy/common/checkout/scm/svn.py
@@ -120,16 +120,21 @@ class SVN(SCM):
field_count = 6 if self._svn_version() > "1.6" else 5
return "^(?P<status>[%s]).{%s} (?P<filename>.+)$" % (expected_types, field_count)
- def _add_parent_directories(self, path):
+ def _add_parent_directories(self, path, recurse):
"""Does 'svn add' to the path and its parents."""
if self.in_working_directory(path):
return
- self.add(path)
+ self.add(path, recurse=recurse)
- def add_list(self, paths, return_exit_code=False):
+ def add_list(self, paths, return_exit_code=False, recurse=True):
for path in paths:
- self._add_parent_directories(os.path.dirname(os.path.abspath(path)))
- return self._run_svn(["add"] + paths, return_exit_code=return_exit_code)
+ self._add_parent_directories(os.path.dirname(os.path.abspath(path)),
+ recurse=False)
+ if recurse:
+ cmd = ["add"] + paths
+ else:
+ cmd = ["add", "--depth", "empty"] + paths
+ return self._run_svn(cmd, return_exit_code=return_exit_code)
def _delete_parent_directories(self, path):
if not self.in_working_directory(path):
« no previous file with comments | « Tools/Scripts/webkitpy/common/checkout/scm/scm_unittest.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698