Index: tools/perf/page_sets/top_25.py |
diff --git a/tools/perf/page_sets/top_25.py b/tools/perf/page_sets/top_25.py |
index aa5d53aa09e3c88b82f7bad285c2405615ccc2c4..2df0574a4daad9adc59808adf39c26bc086ab898 100644 |
--- a/tools/perf/page_sets/top_25.py |
+++ b/tools/perf/page_sets/top_25.py |
@@ -16,12 +16,13 @@ def _WaitForLocationChange(action_runner, old_href): |
class Top25Page(page_module.Page): |
- def __init__(self, url, page_set, name=''): |
+ def __init__(self, url, page_set, name='', credentials=None): |
super(Top25Page, self).__init__( |
url=url, page_set=page_set, name=name, |
credentials_path='data/credentials.json') |
self.user_agent_type = 'desktop' |
self.archive_data_file = 'data/top_25.json' |
+ self.credentials = credentials |
def RunSmoothness(self, action_runner): |
interaction = action_runner.BeginGestureInteraction( |
@@ -109,18 +110,6 @@ class GoogleCalendarPage(Top25Page): |
interaction.End() |
-class GoogleImageSearchPage(Top25Page): |
- |
- """ Why: tough image case; top google properties """ |
- |
- def __init__(self, page_set): |
- super(GoogleImageSearchPage, self).__init__( |
- url='https://www.google.com/search?q=cats&tbm=isch', |
- page_set=page_set) |
- |
- self.credentials = 'google' |
- |
- |
class GoogleDocPage(Top25Page): |
""" Why: productivity, top google properties; Sample doc in the link """ |
@@ -240,26 +229,7 @@ class FacebookPage(Top25Page): |
interaction.End() |
-class LinkedinPage(Top25Page): |
- |
- """ Why: #12 (Alexa global),Public profile """ |
- |
- def __init__(self, page_set): |
- super(LinkedinPage, self).__init__( |
- url='http://www.linkedin.com/in/linustorvalds', |
- page_set=page_set, |
- name='LinkedIn') |
- |
- |
-class WikipediaPage(Top25Page): |
- |
- """ Why: #6 (Alexa) most visited worldwide,Picked an interesting page """ |
- def __init__(self, page_set): |
- super(WikipediaPage, self).__init__( |
- url='http://en.wikipedia.org/wiki/Wikipedia', |
- page_set=page_set, |
- name='Wikipedia (1 tab)') |
class TwitterPage(Top25Page): |
@@ -317,18 +287,6 @@ class ESPNPage(Top25Page): |
interaction.End() |
-class WeatherDotComPage(Top25Page): |
- |
- """ Why: #7 (Alexa news); #27 total time spent,Picked interesting page """ |
- |
- def __init__(self, page_set): |
- super(WeatherDotComPage, self).__init__( |
- # pylint: disable=C0301 |
- url='http://www.weather.com/weather/right-now/Mountain+View+CA+94043', |
- page_set=page_set, |
- name='Weather.com') |
- |
- |
class YahooGamesPage(Top25Page): |
""" Why: #1 games according to Alexa (with actual games in it) """ |
@@ -356,19 +314,33 @@ class Top25PageSet(page_set_module.PageSet): |
self.AddPage(GoogleWebSearchPage(self)) |
self.AddPage(GmailPage(self)) |
self.AddPage(GoogleCalendarPage(self)) |
- self.AddPage(GoogleImageSearchPage(self)) |
+ # Why: tough image case; top google properties |
+ self.AddPage( |
+ Top25Page('https://www.google.com/search?q=cats&tbm=isch', |
+ page_set=self, credentials='google')) |
self.AddPage(GoogleDocPage(self)) |
self.AddPage(GooglePlusPage(self)) |
self.AddPage(YoutubePage(self)) |
self.AddPage(BlogspotPage(self)) |
self.AddPage(WordpressPage(self)) |
self.AddPage(FacebookPage(self)) |
- self.AddPage(LinkedinPage(self)) |
- self.AddPage(WikipediaPage(self)) |
+ # Why: #12 (Alexa global), Public profile. |
+ self.AddPage( |
+ Top25Page( |
+ 'http://www.linkedin.com/in/linustorvalds', self, 'LinkedIn')) |
ernstm
2014/10/27 21:30:04
to be consistent with the other pages: page_set=se
|
+ # Why: #6 (Alexa) most visited worldwide,Picked an interesting page |
+ self.AddPage( |
+ Top25Page( |
+ 'http://en.wikipedia.org/wiki/Wikipedia', page_set=self, |
+ name='Wikipedia (1 tab)')) |
self.AddPage(TwitterPage(self)) |
self.AddPage(PinterestPage(self)) |
self.AddPage(ESPNPage(self)) |
- self.AddPage(WeatherDotComPage(self)) |
+ # Why: #7 (Alexa news); #27 total time spent, picked interesting page. |
+ self.AddPage(Top25Page( |
+ url='http://www.weather.com/weather/right-now/Mountain+View+CA+94043', |
+ page_set=self, |
+ name='Weather.com')) |
self.AddPage(YahooGamesPage(self)) |
other_urls = [ |