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

Side by Side Diff: tools/perf/perf_tools/startup_benchmark.py

Issue 14352002: Rename startup_tests.py Telemetry test to startup_benchmark.py (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 7 years, 8 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 unified diff | Download patch
« no previous file with comments | « no previous file | tools/perf/perf_tools/startup_tests.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 # Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 from telemetry.page import page_benchmark 5 from telemetry.page import page_benchmark
6 6
7 # Test how long Chrome takes to load when warm. 7 # Test how long Chrome takes to load when warm.
8 class PerfWarm(page_benchmark.PageBenchmark): 8 class PerfWarm(page_benchmark.PageBenchmark):
9 def __init__(self): 9 def __init__(self):
10 super(PerfWarm, self).__init__(needs_browser_restart_after_each_run=True, 10 super(PerfWarm, self).__init__(needs_browser_restart_after_each_run=True,
11 discard_first_result=True) 11 discard_first_result=True)
12 12
13 def CustomizeBrowserOptions(self, options): 13 def CustomizeBrowserOptions(self, options):
14 options.AppendExtraBrowserArg('--dom-automation') 14 options.AppendExtraBrowserArg('--dom-automation')
15 options.AppendExtraBrowserArg('--reduce-security-for-dom-automation-tests') 15 options.AppendExtraBrowserArg('--reduce-security-for-dom-automation-tests')
16 16
17 def MeasurePage(self, page, tab, results): 17 def MeasurePage(self, page, tab, results):
18 result = tab.EvaluateJavaScript(""" 18 result = tab.EvaluateJavaScript("""
19 domAutomationController.getBrowserHistogram( 19 domAutomationController.getBrowserHistogram(
20 "Startup.BrowserMessageLoopStartTimeFromMainEntry") 20 "Startup.BrowserMessageLoopStartTimeFromMainEntry")
21 """) 21 """)
22 results.Add('startup_time', 'ms', result) 22 results.Add('startup_time', 'ms', result)
OLDNEW
« no previous file with comments | « no previous file | tools/perf/perf_tools/startup_tests.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698