OLD | NEW |
---|---|
(Empty) | |
1 # Copyright 2014 The Chromium Authors. All rights reserved. | |
2 # Use of this source code is governed by a BSD-style license that can be | |
3 # found in the LICENSE file. | |
4 from telemetry.page import page as page_module | |
5 from telemetry.page import page_set as page_set_module | |
6 | |
7 | |
8 class Typical25MobilePage(page_module.Page): | |
9 | |
10 def __init__(self, url, page_set, name=''): | |
11 super(Typical25MobilePage, self).__init__( | |
12 url=url, page_set=page_set, name=name, | |
13 credentials_path = 'data/credentials.json') | |
14 self.user_agent_type = 'mobile' | |
15 self.archive_data_file = 'data/typical_25_mobile.json' | |
16 | |
17 def RunPowerPageInteractions(self, action_runner): | |
18 action_runner.Wait(20) | |
19 action_runner.ScrollPage() | |
20 action_runner.Wait(20) | |
21 | |
22 class Typical25MobilePageSet(page_set_module.PageSet): | |
tonyg
2014/10/21 16:20:54
What's the cycle time like w/ 25 URLs and 40s paus
sullivan
2014/10/21 16:36:35
I am still trying to record the page set so I can
sullivan
2014/10/21 21:11:14
Cycle time was indeed too long. Cut it down to 10
| |
23 | |
24 """ 25 typical mobile pages, used for power testing. """ | |
25 | |
26 def __init__(self): | |
27 super(Typical25MobilePageSet, self).__init__( | |
28 user_agent_type='mobile', # Android acceptance uses desktop. | |
29 archive_data_file='data/typical_25_mobile.json', | |
30 bucket=page_set_module.PARTNER_BUCKET) | |
31 | |
32 urls_list = [ | |
33 'm.facebook.com/barackobama', | |
34 # Why: featured wikipedia article with lots of pictures | |
35 'http://en.m.wikipedia.org/wiki/Yellowstone_fires_of_1988', | |
36 # Why: current top Q&A on popular Japanese site | |
37 'http://m.chiebukuro.yahoo.co.jp/detail/q10136829180', | |
38 'http://www.dailymotion.com/us/channel/kids/', | |
39 'http://www.amazon.com/gp/aw/d/B00DR0PDNE', | |
40 'http://mobile.twitter.com/katyperry', | |
41 # Why: popular page on Russian social networking site | |
42 'http://m.vk.com/shakira', | |
43 'http://www.yahoo.com/', | |
44 'http://m.huffpost.com/us/entry/6004486', | |
45 'http://www.cnn.com/2014/03/31/showbiz/tv/himym-finale/index.html', | |
46 'http://www.cnet.com/news/get-a-39-inch-led-hdtv-for-199-99/', | |
47 # Why: RTL language site | |
48 'http://www.aljazeera.net/portal', | |
49 'http://m.ebay.com/itm/351157205404', | |
50 'http://m.tmz.com/#Article/2014/05/16/billboard-music-awards-alki-david-m ichael-jackson-hologram-lawsuit', | |
51 'http://www.buzzfeed.com/expresident/pictures-that-will-restore-your-fait h-in-humanity?s=mobile#1eumyrj', | |
52 'http://mashable.com/2011/10/23/top-mashable-infographics/', | |
53 'http://siriuslymeg.tumblr.com/', | |
54 'http://auto.qq.com/a/20141021/006886.htm', | |
55 'http://wapbaike.baidu.com/', | |
56 ] | |
57 | |
58 for url in urls_list: | |
59 self.AddPage(Typical25MobilePage(url, self)) | |
OLD | NEW |