Chromium Code Reviews| Index: tools/perf/measurements/v8_detached_context_age_in_gc_unittest.py |
| diff --git a/tools/perf/measurements/v8_detached_context_age_in_gc_unittest.py b/tools/perf/measurements/v8_detached_context_age_in_gc_unittest.py |
| index 42e53305d8f8c34f9acd524590e334ecfbbfa5dc..215edaa346eed277f95dc59f2ef56371ab92929f 100644 |
| --- a/tools/perf/measurements/v8_detached_context_age_in_gc_unittest.py |
| +++ b/tools/perf/measurements/v8_detached_context_age_in_gc_unittest.py |
| @@ -27,12 +27,17 @@ class FakeTab(object): |
| self.histograms = histograms |
| self.current_histogram_index = 0 |
| - def EvaluateJavaScript(self, script): |
| - if 'V8.DetachedContextAgeInGC' in script: |
| + def EvaluateJavaScript(self, script, **kwargs): |
| + histogram_name = 'V8.DetachedContextAgeInGC' |
| + if kwargs.get('name') == histogram_name or histogram_name in script: |
|
perezju
2017/02/14 11:42:04
Tweaked to work both before and after applying the
|
| self.current_histogram_index += 1 |
| return self.histograms[self.current_histogram_index - 1] |
| return '{}' |
| + # TODO(catapult:3028): Remove after migration to new JS API completed. |
| + def EvaluateJavaScript2(self, script, **kwargs): |
| + return self.EvaluateJavaScript(script, **kwargs) |
| + |
| def CollectGarbage(self): |
| pass |