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

Unified Diff: tools/auto_bisect/bisect_results.py

Issue 661803003: Revert of Refactor source_control.py and add a test. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 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 | « tools/auto_bisect/bisect_perf_regression_test.py ('k') | tools/auto_bisect/source_control.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/auto_bisect/bisect_results.py
diff --git a/tools/auto_bisect/bisect_results.py b/tools/auto_bisect/bisect_results.py
index 59cb94d7db07fa024ab389f283bf9f5eb8779f46..144962fd7038fa516f57b955830031fc8b5aeedb 100644
--- a/tools/auto_bisect/bisect_results.py
+++ b/tools/auto_bisect/bisect_results.py
@@ -7,7 +7,6 @@
import bisect_utils
import math_utils
-import source_control
import ttest
@@ -49,10 +48,11 @@
class BisectResults(object):
- def __init__(self, depot_registry):
+ def __init__(self, depot_registry, source_control):
self._depot_registry = depot_registry
self.revision_data = {}
self.error = None
+ self._source_control = source_control
@staticmethod
def _FindOtherRegressions(revision_data_sorted, bad_greater_than_good):
@@ -232,7 +232,7 @@
changes.append([last_depot, contents[0]])
for c in changes:
os.chdir(c[0])
- info = source_control.QueryRevisionInfo(c[1])
+ info = self._source_control.QueryRevisionInfo(c[1])
culprit_revisions.append((c[1], info, None))
else:
for i in xrange(last_broken_revision_index, len(revision_data_sorted)):
@@ -240,7 +240,7 @@
if k == first_working_revision:
break
self._depot_registry.ChangeToDepotDir(v['depot'])
- info = source_control.QueryRevisionInfo(k)
+ info = self._source_control.QueryRevisionInfo(k)
culprit_revisions.append((k, info, v['depot']))
os.chdir(cwd)
« no previous file with comments | « tools/auto_bisect/bisect_perf_regression_test.py ('k') | tools/auto_bisect/source_control.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698