Chromium Code Reviews| 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 from core import perf_benchmark | 5 from core import perf_benchmark | 
| 6 from telemetry.timeline import chrome_trace_category_filter | 6 from telemetry.timeline import chrome_trace_category_filter | 
| 7 from telemetry.web_perf import timeline_based_measurement | 7 from telemetry.web_perf import timeline_based_measurement | 
| 8 import page_sets | 8 import page_sets | 
| 9 from telemetry import benchmark | 9 from telemetry import benchmark | 
| 10 | 10 | 
| (...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 123 @benchmark.Enabled('mac') | 123 @benchmark.Enabled('mac') | 
| 124 class BattOrTrivialPages(_BattOrBenchmark): | 124 class BattOrTrivialPages(_BattOrBenchmark): | 
| 125 | 125 | 
| 126 def CreateStorySet(self, options): | 126 def CreateStorySet(self, options): | 
| 127 # We want it to wait for 30 seconds to be comparable to legacy power tests. | 127 # We want it to wait for 30 seconds to be comparable to legacy power tests. | 
| 128 return page_sets.MacGpuTrivialPagesStorySet(wait_in_seconds=30) | 128 return page_sets.MacGpuTrivialPagesStorySet(wait_in_seconds=30) | 
| 129 | 129 | 
| 130 @classmethod | 130 @classmethod | 
| 131 def Name(cls): | 131 def Name(cls): | 
| 132 return 'battor.trivial_pages' | 132 return 'battor.trivial_pages' | 
| 133 | |
| 
 
petrcermak
2016/08/25 09:57:19
nit: there should be 2 blank lines between top-lev
 
rnephew (Reviews Here)
2016/08/25 15:28:57
Charlies CL at https://codereview.chromium.org/223
 
 | |
| 134 class DesktopBattOrLongRunning(_BattOrBenchmark): | |
| 
 
rnephew (Reviews Here)
2016/08/24 17:50:45
If my understanding of how the system_health.memor
 
petrcermak
2016/08/25 09:57:18
All benchmarks that don't specify |case| or have c
 
petrcermak
2016/08/25 09:57:18
If for some reason you decide to spin up a separat
 
 | |
| 135 PLATFORM = 'desktop' | |
| 136 | |
| 137 def CreateStorySet(self, options): | |
| 138 return page_sets.SystemHealthStorySet(platform=self.PLATFORM, | |
| 139 case='long_running') | |
| 140 | |
| 141 @classmethod | |
| 142 def ShouldTearDownStateAfterEachStoryRun(cls): | |
| 143 return True | |
| 144 | |
| 145 @classmethod | |
| 146 def Name(cls): | |
| 147 return 'battor.long_running_%s' % cls.PLATFORM | |
| 148 | |
| 149 | |
| 150 class MobileBattOrLongRunning(_BattOrBenchmark): | |
| 151 PLATFORM = 'mobile' | |
| 152 | |
| 153 def CreateStorySet(self, options): | |
| 154 return page_sets.SystemHealthStorySet(platform=self.PLATFORM, | |
| 155 case='long_running') | |
| 156 | |
| 157 @classmethod | |
| 158 def ShouldTearDownStateAfterEachStoryRun(cls): | |
| 159 return True | |
| 160 | |
| 161 @classmethod | |
| 162 def Name(cls): | |
| 163 return 'battor.long_running_%s' % cls.PLATFORM | |
| OLD | NEW |