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

Unified Diff: tools/perf/perf_tools/startup_measurement.py

Issue 12389073: Collect tab timing information for use in telementry-based startup tests (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix telemetry tests with reference builds. Created 7 years, 7 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
Index: tools/perf/perf_tools/startup_measurement.py
diff --git a/tools/perf/perf_tools/startup_measurement.py b/tools/perf/perf_tools/startup_measurement.py
index 0c4284ffbc2acd54d8a9027209d2561929b6af88..f1150904f459e228c10c2a7951ef5f77afa8236b 100644
--- a/tools/perf/perf_tools/startup_measurement.py
+++ b/tools/perf/perf_tools/startup_measurement.py
@@ -19,11 +19,23 @@ class PerfWarm(page_measurement.PageMeasurement):
discard_first_result=True)
def CustomizeBrowserOptions(self, options):
+ options.AppendExtraBrowserArg('--enable-stats-collection-bindings')
+ options.AppendExtraBrowserArg(
+ '--reduce-security-for-stats-collection-tests')
+
+ # Old commandline flags used for reference builds.
options.AppendExtraBrowserArg('--dom-automation')
- options.AppendExtraBrowserArg('--reduce-security-for-dom-automation-tests')
+ options.AppendExtraBrowserArg(
+ '--reduce-security-for-dom-automation-tests')
def MeasurePage(self, page, tab, results):
- get_histogram_js = "domAutomationController.getBrowserHistogram(\"%s\")"
+ # TODO(jeremy): Remove references to
+ # domAutomationController.getBrowserHistogram when we update the reference
+ # builds.
+ get_histogram_js = ('(window.statsCollectionController ?'
+ 'statsCollectionController :'
+ 'domAutomationController).getBrowserHistogram("%s")')
+
for display_name, histogram_name in self.HISTOGRAMS_TO_RECORD.iteritems():
result = tab.EvaluateJavaScript(get_histogram_js % histogram_name)
« tools/perf/perf_tools/histogram_metric.py ('K') | « tools/perf/perf_tools/page_cycler.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698