summaryrefslogtreecommitdiffstats
path: root/content
diff options
context:
space:
mode:
authornednguyen@chromium.org <nednguyen@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-08-19 21:55:59 +0000
committernednguyen@chromium.org <nednguyen@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-08-19 21:57:11 +0000
commit96478a245cd8e93c26c0e55526dab4ccde384d40 (patch)
treed225ae422b5b9b963dabf2f50b4a0f9c16d8257d /content
parent97a749d428eaba4352c335c6b5f0e6a8cc8cad08 (diff)
downloadchromium_src-96478a245cd8e93c26c0e55526dab4ccde384d40.zip
chromium_src-96478a245cd8e93c26c0e55526dab4ccde384d40.tar.gz
chromium_src-96478a245cd8e93c26c0e55526dab4ccde384d40.tar.bz2
Remove deprecated methods related to tracing in browser.py.
Switch callsites to use tracing_controller. BUG=356763 Review URL: https://codereview.chromium.org/471763003 Cr-Commit-Position: refs/heads/master@{#290671} git-svn-id: svn://svn.chromium.org/chrome/trunk/src@290671 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content')
-rw-r--r--content/test/gpu/gpu_tests/memory.py11
1 files changed, 9 insertions, 2 deletions
diff --git a/content/test/gpu/gpu_tests/memory.py b/content/test/gpu/gpu_tests/memory.py
index dbb111f..c8eadc4 100644
--- a/content/test/gpu/gpu_tests/memory.py
+++ b/content/test/gpu/gpu_tests/memory.py
@@ -6,6 +6,8 @@ import page_sets
from telemetry import benchmark
from telemetry.page import page_test
+from telemetry.core.platform import tracing_category_filter
+from telemetry.core.platform import tracing_options
from telemetry.timeline import counter
from telemetry.timeline import model
@@ -64,7 +66,7 @@ test_harness_script = r"""
class _MemoryValidator(page_test.PageTest):
def ValidateAndMeasurePage(self, page, tab, results):
- timeline_data = tab.browser.StopTracing()
+ timeline_data = tab.browser.platform.tracing_controller.Stop()
timeline_model = model.TimelineModel(timeline_data)
for process in timeline_model.GetAllProcesses():
if 'gpu.GpuMemoryUsage' in process.counters:
@@ -86,7 +88,12 @@ class _MemoryValidator(page_test.PageTest):
# FIXME: Remove webkit.console when blink.console lands in chromium and the
# ref builds are updated. crbug.com/386847
custom_categories = ['webkit.console', 'blink.console', 'gpu']
- tab.browser.StartTracing(','.join(custom_categories), 60)
+ category_filter = tracing_category_filter.TracingCategoryFilter()
+ for c in custom_categories:
+ category_filter.AddIncludedCategory(c)
+ options = tracing_options.TracingOptions()
+ options.enable_chrome_trace = True
+ tab.browser.platform.tracing_controller.Start(options, category_filter, 60)
def _FormatException(self, low_or_high, mb_used):
return 'Memory allocation too %s (was %d MB, should be %d MB +/- %d MB)' % (