Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(7)

Side by Side Diff: tools/perf/benchmarks/media.py

Issue 149793002: Enable media android tests and make --disable-gesture-requirement-for-media-playback default for me… (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 6 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | tools/perf/measurements/media.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 import sys
6
7 from telemetry import test 5 from telemetry import test
8 from telemetry.page import page_measurement 6 from telemetry.page import page_measurement
9 7
10 from measurements import media 8 from measurements import media
11 9
12 10
13 class MSEMeasurement(page_measurement.PageMeasurement): 11 class MSEMeasurement(page_measurement.PageMeasurement):
14 def MeasurePage(self, page, tab, results): 12 def MeasurePage(self, page, tab, results):
15 media_metric = tab.EvaluateJavaScript('window.__testMetrics') 13 media_metric = tab.EvaluateJavaScript('window.__testMetrics')
16 trace = media_metric['id'] if 'id' in media_metric else None 14 trace = media_metric['id'] if 'id' in media_metric else None
(...skipping 13 matching lines...) Expand all
30 28
31 class MediaNetworkSimulation(test.Test): 29 class MediaNetworkSimulation(test.Test):
32 """Obtains media metrics under different network simulations.""" 30 """Obtains media metrics under different network simulations."""
33 test = media.Media 31 test = media.Media
34 page_set = 'page_sets/media_cns_cases.json' 32 page_set = 'page_sets/media_cns_cases.json'
35 33
36 class MediaAndroid(test.Test): 34 class MediaAndroid(test.Test):
37 """Obtains media metrics for key user scenarios on Android.""" 35 """Obtains media metrics for key user scenarios on Android."""
38 test = media.Media 36 test = media.Media
39 tag = 'android' 37 tag = 'android'
40 # Disable media-tests on Android: crbug/329691
41 # Before re-enabling on Android, make sure the new 4K content,
42 # garden2_10s*, passes.
43 enabled = not sys.platform.startswith('linux')
44 page_set = 'page_sets/tough_video_cases.json' 38 page_set = 'page_sets/tough_video_cases.json'
45 # Exclude crowd* media files (50fps 2160p). 39 # Exclude 4k and 50 fps media files (garden* & crowd*).
46 options = { 40 options = {
47 'page_filter_exclude': '.*crowd.*' 41 'page_filter_exclude': '.*(crowd|garden).*'
48 } 42 }
49 43
50 def CustomizeBrowserOptions(self, options):
51 # Needed to run media actions in JS in Android.
52 options.AppendExtraBrowserArgs(
53 '--disable-gesture-requirement-for-media-playback')
54
55 class MediaChromeOS(test.Test): 44 class MediaChromeOS(test.Test):
56 """Obtains media metrics for key user scenarios on ChromeOS.""" 45 """Obtains media metrics for key user scenarios on ChromeOS."""
57 test = media.Media 46 test = media.Media
58 tag = 'chromeOS' 47 tag = 'chromeOS'
59 page_set = 'page_sets/tough_video_cases.json' 48 page_set = 'page_sets/tough_video_cases.json'
60 # Exclude crowd* media files (50fps 2160p): crbug/331816 49 # Exclude crowd* media files (50fps 2160p): crbug/331816
61 options = { 50 options = {
62 'page_filter_exclude': '.*crowd.*' 51 'page_filter_exclude': '.*crowd.*'
63 } 52 }
64 53
65 def CustomizeBrowserOptions(self, options):
66 # Needed to run media actions in JS in Android.
67 options.AppendExtraBrowserArgs(
68 '--disable-gesture-requirement-for-media-playback')
69
70 class MediaSourceExtensions(test.Test): 54 class MediaSourceExtensions(test.Test):
71 """Obtains media metrics for key media source extensions functions.""" 55 """Obtains media metrics for key media source extensions functions."""
72 test = media.Media
73 # Disable MSE media-tests on Android and linux: crbug/329691
74 # Disable MSE tests on windows 8 crbug.com/330910
75 test = MSEMeasurement 56 test = MSEMeasurement
76 page_set = 'page_sets/mse_cases.json' 57 page_set = 'page_sets/mse_cases.json'
77 58
78 def CustomizeBrowserOptions(self, options): 59 def CustomizeBrowserOptions(self, options):
79 # Needed to allow XHR requests to return stream objects. 60 # Needed to allow XHR requests to return stream objects.
80 options.AppendExtraBrowserArgs( 61 options.AppendExtraBrowserArgs(
81 ['--enable-experimental-web-platform-features', 62 ['--enable-experimental-web-platform-features',
82 '--disable-gesture-requirement-for-media-playback']) 63 '--disable-gesture-requirement-for-media-playback'])
OLDNEW
« no previous file with comments | « no previous file | tools/perf/measurements/media.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698