| OLD | NEW |
| 1 # Copyright 2013 The Chromium Authors. All rights reserved. | 1 # Copyright 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 core import perf_benchmark | 5 from core import perf_benchmark |
| 6 | 6 |
| 7 from measurements import tab_switching | 7 from measurements import tab_switching |
| 8 import page_sets | 8 import page_sets |
| 9 from telemetry import benchmark | 9 from telemetry import benchmark |
| 10 | 10 |
| 11 | 11 |
| 12 @benchmark.Enabled('has tabs') | 12 #@benchmark.Enabled('has tabs') |
| 13 @benchmark.Disabled('mac-reference') # http://crbug.com/612774 | 13 @benchmark.Disabled('mac-reference') # http://crbug.com/612774 |
| 14 @benchmark.Disabled('android') # http://crbug.com/460084 | 14 @benchmark.Disabled('android') # http://crbug.com/460084 |
| 15 @benchmark.Disabled('all') # http://crbug.com/710524 |
| 15 class TabSwitchingTypical25(perf_benchmark.PerfBenchmark): | 16 class TabSwitchingTypical25(perf_benchmark.PerfBenchmark): |
| 16 """This test records the MPArch.RWH_TabSwitchPaintDuration histogram. | 17 """This test records the MPArch.RWH_TabSwitchPaintDuration histogram. |
| 17 | 18 |
| 18 The histogram is a measure of the time between when a tab was requested to be | 19 The histogram is a measure of the time between when a tab was requested to be |
| 19 shown, and when first paint occurred. The script opens 25 pages in different | 20 shown, and when first paint occurred. The script opens 25 pages in different |
| 20 tabs, waits for them to load, and then switches to each tab and records the | 21 tabs, waits for them to load, and then switches to each tab and records the |
| 21 metric. The pages were chosen from Alexa top ranking sites. | 22 metric. The pages were chosen from Alexa top ranking sites. |
| 22 """ | 23 """ |
| 23 test = tab_switching.TabSwitching | 24 test = tab_switching.TabSwitching |
| 24 | 25 |
| 25 def CreateStorySet(self, options): | 26 def CreateStorySet(self, options): |
| 26 return page_sets.Typical25PageSet(run_no_page_interactions=True) | 27 return page_sets.Typical25PageSet(run_no_page_interactions=True) |
| 27 | 28 |
| 28 @classmethod | 29 @classmethod |
| 29 def Name(cls): | 30 def Name(cls): |
| 30 return 'tab_switching.typical_25' | 31 return 'tab_switching.typical_25' |
| 31 | 32 |
| 32 @classmethod | 33 @classmethod |
| 33 def ShouldTearDownStateAfterEachStoryRun(cls): | 34 def ShouldTearDownStateAfterEachStoryRun(cls): |
| 34 return False | 35 return False |
| OLD | NEW |