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

Side by Side Diff: chrome/test/data/webui/media_router/media_router_container_test_base.js

Issue 2862393002: [Media Router] Force DEFAULT cast mode when starting presentations from content. (Closed)
Patch Set: Fix bug found by closure compiler Created 3 years, 7 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
OLDNEW
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 /** @fileoverview Provides basic utility functions and variables for 5 /** @fileoverview Provides basic utility functions and variables for
6 * media-router-container tests. 6 * media-router-container tests.
7 */ 7 */
8 8
9 cr.define('media_router_container_test_base', function() { 9 cr.define('media_router_container_test_base', function() {
10 function init(container) { 10 function init(container) {
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
78 */ 78 */
79 var fakeBlockingIssue = new media_router.Issue( 79 var fakeBlockingIssue = new media_router.Issue(
80 1, 'Issue Title 1', 'Issue Message 1', 0, 1, 80 1, 'Issue Title 1', 'Issue Message 1', 0, 1,
81 'route id 1', true, 1234); 81 'route id 1', true, 1234);
82 82
83 /** 83 /**
84 * The list of CastModes to show. 84 * The list of CastModes to show.
85 * @type {!Array<!media_router.CastMode>} 85 * @type {!Array<!media_router.CastMode>}
86 */ 86 */
87 var fakeCastModeList = [ 87 var fakeCastModeList = [
88 new media_router.CastMode(0x1, 'Description 0', 'google.com'), 88 new media_router.CastMode(0x1, 'Cast google.com', 'google.com', false),
89 new media_router.CastMode(0x2, 'Description 1', null), 89 new media_router.CastMode(0x2, 'Description 1', null, false),
90 new media_router.CastMode(0x4, 'Description 2', null), 90 new media_router.CastMode(0x4, 'Description 2', null, false),
91 ]; 91 ];
92 92
93 /** 93 /**
94 * The list of CastModes to show with non-default modes only. 94 * The list of CastModes to show with non-default modes only.
95 * @type {!Array<!media_router.CastMode>} 95 * @type {!Array<!media_router.CastMode>}
96 */ 96 */
97 var fakeCastModeListWithNonDefaultModesOnly = [ 97 var fakeCastModeListWithNonDefaultModesOnly = [
98 new media_router.CastMode(0x2, 'Description 1', null), 98 new media_router.CastMode(0x2, 'Description 1', null, false),
99 new media_router.CastMode(0x4, 'Description 2', null), 99 new media_router.CastMode(0x4, 'Description 2', null, false),
100 new media_router.CastMode(0x8, 'Description 3', null), 100 new media_router.CastMode(0x8, 'Description 3', null, false),
101 ]; 101 ];
102 102
103 /** 103 /**
104 * The list of CastModes to show with DEFAULT forced.
105 * @type {!Array<!media_router.CastMode>}
106 */
107 var fakeCastModeListWithDefaultModeForced = [
108 new media_router.CastMode(0x1, 'Cast google.com', 'google.com', true),
109 new media_router.CastMode(0x4, 'Description 2', null, false),
110 new media_router.CastMode(0x8, 'Description 3', null, false),
111 ];
112
113 /**
104 * The blocking issue to show. 114 * The blocking issue to show.
105 * @type {!media_router.Issue} 115 * @type {!media_router.Issue}
106 */ 116 */
107 var fakeNonBlockingIssue = new media_router.Issue( 117 var fakeNonBlockingIssue = new media_router.Issue(
108 2, 'Issue Title 2', 'Issue Message 2', 0, 1, 118 2, 'Issue Title 2', 'Issue Message 2', 0, 1,
109 'route id 2', false, 1234); 119 'route id 2', false, 1234);
110 120
111 /** 121 /**
112 * The list of current routes. 122 * The list of current routes.
113 * @type {!Array<!media_router.Route>} 123 * @type {!Array<!media_router.Route>}
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
183 return { 193 return {
184 checkCurrentView: checkCurrentView, 194 checkCurrentView: checkCurrentView,
185 checkElementsVisibleWithId: checkElementsVisibleWithId, 195 checkElementsVisibleWithId: checkElementsVisibleWithId,
186 checkElementVisible: checkElementVisible, 196 checkElementVisible: checkElementVisible,
187 checkElementVisibleWithId: checkElementVisibleWithId, 197 checkElementVisibleWithId: checkElementVisibleWithId,
188 checkElementText: checkElementText, 198 checkElementText: checkElementText,
189 fakeBlockingIssue: fakeBlockingIssue, 199 fakeBlockingIssue: fakeBlockingIssue,
190 fakeCastModeList: fakeCastModeList, 200 fakeCastModeList: fakeCastModeList,
191 fakeCastModeListWithNonDefaultModesOnly: 201 fakeCastModeListWithNonDefaultModesOnly:
192 fakeCastModeListWithNonDefaultModesOnly, 202 fakeCastModeListWithNonDefaultModesOnly,
203 fakeCastModeListWithDefaultModeForced:
204 fakeCastModeListWithDefaultModeForced,
193 fakeNonBlockingIssue: fakeNonBlockingIssue, 205 fakeNonBlockingIssue: fakeNonBlockingIssue,
194 fakeRouteList: fakeRouteList, 206 fakeRouteList: fakeRouteList,
195 fakeRouteListWithLocalRoutesOnly: fakeRouteListWithLocalRoutesOnly, 207 fakeRouteListWithLocalRoutesOnly: fakeRouteListWithLocalRoutesOnly,
196 fakeSinkList: fakeSinkList, 208 fakeSinkList: fakeSinkList,
197 searchTextAll: searchTextAll, 209 searchTextAll: searchTextAll,
198 searchTextNone: searchTextNone, 210 searchTextNone: searchTextNone,
199 searchTextOne: searchTextOne, 211 searchTextOne: searchTextOne,
200 }; 212 };
201 } 213 }
202 return {init: init}; 214 return {init: init};
203 }); 215 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698