| OLD | NEW |
| 1 # Copyright 2016 The Chromium Authors. All rights reserved. | 1 # Copyright 2016 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 import re | 5 import re |
| 6 | 6 |
| 7 from core import perf_benchmark | 7 from core import perf_benchmark |
| 8 from telemetry import benchmark | 8 from telemetry import benchmark |
| 9 from telemetry.timeline import chrome_trace_category_filter | 9 from telemetry.timeline import chrome_trace_category_filter |
| 10 from telemetry.web_perf import timeline_based_measurement | 10 from telemetry.web_perf import timeline_based_measurement |
| (...skipping 17 matching lines...) Expand all Loading... |
| 28 | 28 |
| 29 https://goo.gl/Jek2NL. | 29 https://goo.gl/Jek2NL. |
| 30 """ | 30 """ |
| 31 | 31 |
| 32 def CreateTimelineBasedMeasurementOptions(self): | 32 def CreateTimelineBasedMeasurementOptions(self): |
| 33 options = timeline_based_measurement.Options( | 33 options = timeline_based_measurement.Options( |
| 34 chrome_trace_category_filter.ChromeTraceCategoryFilter()) | 34 chrome_trace_category_filter.ChromeTraceCategoryFilter()) |
| 35 options.config.chrome_trace_config.category_filter.AddFilterString('rail') | 35 options.config.chrome_trace_config.category_filter.AddFilterString('rail') |
| 36 options.config.enable_battor_trace = True | 36 options.config.enable_battor_trace = True |
| 37 options.config.enable_chrome_trace = True | 37 options.config.enable_chrome_trace = True |
| 38 options.SetTimelineBasedMetrics(['clockSyncLatencyMetric', 'powerMetric']) |
| 38 return options | 39 return options |
| 39 | 40 |
| 40 def CreateStorySet(self, options): | 41 def CreateStorySet(self, options): |
| 41 return page_sets.SystemHealthStorySet(platform=self.PLATFORM) | 42 return page_sets.SystemHealthStorySet(platform=self.PLATFORM) |
| 42 | 43 |
| 43 @classmethod | 44 @classmethod |
| 44 def ShouldTearDownStateAfterEachStoryRun(cls): | 45 def ShouldTearDownStateAfterEachStoryRun(cls): |
| 45 return True | 46 return True |
| 46 | 47 |
| 47 @classmethod | 48 @classmethod |
| (...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 182 and load a blank page with multiprocess enabled. | 183 and load a blank page with multiprocess enabled. |
| 183 """ | 184 """ |
| 184 | 185 |
| 185 def SetExtraBrowserOptions(self, options): | 186 def SetExtraBrowserOptions(self, options): |
| 186 options.AppendExtraBrowserArgs( | 187 options.AppendExtraBrowserArgs( |
| 187 ['--webview-sandboxed-renderer']) | 188 ['--webview-sandboxed-renderer']) |
| 188 | 189 |
| 189 @classmethod | 190 @classmethod |
| 190 def Name(cls): | 191 def Name(cls): |
| 191 return 'system_health.webview_startup_multiprocess' | 192 return 'system_health.webview_startup_multiprocess' |
| OLD | NEW |