| 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 page_sets import page_cycler_story | 5 from page_sets import page_cycler_story |
| 6 from telemetry.page import cache_temperature as cache_temperature_module | 6 from telemetry.page import cache_temperature as cache_temperature_module |
| 7 from telemetry.page import shared_page_state | 7 from telemetry.page import shared_page_state |
| 8 from telemetry import story | 8 from telemetry import story |
| 9 | 9 |
| 10 | 10 |
| 11 class LoadingDesktopStorySet(story.StorySet): | 11 class LoadingDesktopStorySet(story.StorySet): |
| 12 | 12 |
| 13 """ A collection of tests to measure loading performance of desktop sites. | 13 """ A collection of tests to measure loading performance of desktop sites. |
| 14 | 14 |
| 15 Desktop centric version of loading_mobile.py | 15 Desktop centric version of loading_mobile.py |
| 16 """ | 16 """ |
| 17 | 17 |
| 18 def __init__(self, cache_temperatures=None): | 18 def __init__(self, cache_temperatures=None): |
| 19 super(LoadingDesktopStorySet, self).__init__( | 19 super(LoadingDesktopStorySet, self).__init__( |
| 20 archive_data_file='data/loading_desktop.json', | 20 archive_data_file='data/loading_desktop.json', |
| 21 cloud_storage_bucket=story.PARTNER_BUCKET, | 21 cloud_storage_bucket=story.PARTNER_BUCKET) |
| 22 verify_names=True) | |
| 23 | 22 |
| 24 if cache_temperatures is None: | 23 if cache_temperatures is None: |
| 25 cache_temperatures = [ | 24 cache_temperatures = [ |
| 26 cache_temperature_module.PCV1_COLD, cache_temperature_module.PCV1_WARM | 25 cache_temperature_module.PCV1_COLD, cache_temperature_module.PCV1_WARM |
| 27 ] | 26 ] |
| 28 # Passed as (story, name) tuple. | 27 # Passed as (story, name) tuple. |
| 29 self.AddStories( | 28 self.AddStories( |
| 30 ['intl_ar_fa_he', 'international'], | 29 ['intl_ar_fa_he', 'international'], |
| 31 [('http://ynet.co.il/', 'Ynet'), | 30 [('http://ynet.co.il/', 'Ynet'), |
| 32 ('http://farsnews.com/', 'FarsNews'), | 31 ('http://farsnews.com/', 'FarsNews'), |
| (...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 108 for temp in cache_temperatures: | 107 for temp in cache_temperatures: |
| 109 self.AddStory(page_cycler_story.PageCyclerStory(url, self, | 108 self.AddStory(page_cycler_story.PageCyclerStory(url, self, |
| 110 shared_page_state_class=shared_page_state.SharedMobilePageState, | 109 shared_page_state_class=shared_page_state.SharedMobilePageState, |
| 111 cache_temperature=temp, tags=tags, name=name)) | 110 cache_temperature=temp, tags=tags, name=name)) |
| 112 | 111 |
| 113 | 112 |
| 114 class LoadingDesktopExpectations(story.expectations.StoryExpectations): | 113 class LoadingDesktopExpectations(story.expectations.StoryExpectations): |
| 115 def SetExpectations(self): | 114 def SetExpectations(self): |
| 116 self.DisableStory( | 115 self.DisableStory( |
| 117 'uol.com.br', [story.expectations.ALL_LINUX], 'crbug.com/723783') | 116 'uol.com.br', [story.expectations.ALL_LINUX], 'crbug.com/723783') |
| OLD | NEW |