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

Unified Diff: tools/perf/measurements/thread_times.py

Issue 737403002: Revert of telemetry: Remove command line args from page test (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 1 month 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/perf/measurements/startup.py ('k') | tools/perf/measurements/thread_times_unittest.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/perf/measurements/thread_times.py
diff --git a/tools/perf/measurements/thread_times.py b/tools/perf/measurements/thread_times.py
index 497d2c93151b6aba3b80bd703715ecedaa5e6f8b..918a06f9bf33cf6f47e9fc3a5328160863f9589a 100644
--- a/tools/perf/measurements/thread_times.py
+++ b/tools/perf/measurements/thread_times.py
@@ -7,15 +7,18 @@
from telemetry.page import page_test
class ThreadTimes(page_test.PageTest):
- def __init__(self, report_silk_details=False,
- action_name_to_run='RunSmoothness'):
- super(ThreadTimes, self).__init__(action_name_to_run=action_name_to_run)
+ def __init__(self):
+ super(ThreadTimes, self).__init__('RunSmoothness')
self._timeline_controller = None
- self._report_silk_details = report_silk_details
+
+ @classmethod
+ def AddCommandLineArgs(cls, parser):
+ parser.add_option('--report-silk-details', action='store_true',
+ help='Report details relevant to silk.')
def WillNavigateToPage(self, page, tab):
self._timeline_controller = timeline_controller.TimelineController()
- if self._report_silk_details:
+ if self.options.report_silk_details:
# We need the other traces in order to have any details to report.
self._timeline_controller.trace_categories = None
else:
@@ -33,7 +36,7 @@
metric = timeline.ThreadTimesTimelineMetric()
renderer_thread = \
self._timeline_controller.model.GetRendererThreadFromTabId(tab.id)
- if self._report_silk_details:
+ if self.options.report_silk_details:
metric.details_to_report = timeline.ReportSilkDetails
metric.AddResults(self._timeline_controller.model, renderer_thread,
self._timeline_controller.smooth_records, results)
« no previous file with comments | « tools/perf/measurements/startup.py ('k') | tools/perf/measurements/thread_times_unittest.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698