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

Unified Diff: Tools/Scripts/webkitpy/common/checkout/baselineoptimizer.py

Issue 423553004: Fix baselineoptimizer issue when deleting a virtual baseline not controlled by scm (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Add test 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 | « no previous file | Tools/Scripts/webkitpy/common/checkout/baselineoptimizer_unittest.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Tools/Scripts/webkitpy/common/checkout/baselineoptimizer.py
diff --git a/Tools/Scripts/webkitpy/common/checkout/baselineoptimizer.py b/Tools/Scripts/webkitpy/common/checkout/baselineoptimizer.py
index a6d6ac198b14b1a15772f21b6fc1452449703632..98ec3d1f015f7bf23b5a6ae1b9e404c59555a58a 100644
--- a/Tools/Scripts/webkitpy/common/checkout/baselineoptimizer.py
+++ b/Tools/Scripts/webkitpy/common/checkout/baselineoptimizer.py
@@ -314,10 +314,15 @@ class BaselineOptimizer(object):
break
_log.debug("Deleting redundant virtual root expected result.")
- if self._skip_scm_commands:
- self._files_to_delete.append(virtual_root_expected_baseline_path)
+ if self._scm.exists(virtual_root_expected_baseline_path):
+ _log.debug(" Deleting (SCM): " + virtual_root_expected_baseline_path)
+ if self._skip_scm_commands:
+ self._files_to_delete.append(virtual_root_expected_baseline_path)
+ else:
+ self._scm.delete(virtual_root_expected_baseline_path)
else:
- self._scm.delete(virtual_root_expected_baseline_path)
+ _log.debug(" Deleting (file system): " + virtual_root_expected_baseline_path)
+ self._filesystem.remove(virtual_root_expected_baseline_path)
def optimize(self, baseline_name):
# The virtual fallback path is the same as the non-virtual one tacked on to the bottom of the non-virtual path.
« no previous file with comments | « no previous file | Tools/Scripts/webkitpy/common/checkout/baselineoptimizer_unittest.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698