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

Side by Side Diff: chrome/test/data/webui/md_bookmarks/md_bookmarks_browsertest.js

Issue 2902103002: MD Bookmarks: Disable 'Open in Incognito Window' when Incognito is disabled (Closed)
Patch Set: Review comment Created 3 years, 6 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 | « chrome/test/BUILD.gn ('k') | chrome/test/data/webui/md_bookmarks/policy_test.js » ('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 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 /** 5 /**
6 * @fileoverview Test suite for the Material Design bookmarks page. 6 * @fileoverview Test suite for the Material Design bookmarks page.
7 */ 7 */
8 var ROOT_PATH = '../../../../../'; 8 var ROOT_PATH = '../../../../../';
9 9
10 GEN_INCLUDE( 10 GEN_INCLUDE(
11 [ROOT_PATH + 'chrome/test/data/webui/polymer_browser_test_base.js']); 11 [ROOT_PATH + 'chrome/test/data/webui/polymer_browser_test_base.js']);
12 GEN('#include "base/command_line.h"'); 12 GEN('#include "base/command_line.h"');
13 GEN('#include "chrome/browser/prefs/incognito_mode_prefs.h"');
14 GEN('#include "chrome/browser/ui/webui/md_bookmarks/md_bookmarks_browsertest.h"' );
13 15
14 function MaterialBookmarksBrowserTest() {} 16 function MaterialBookmarksBrowserTest() {}
15 17
16 MaterialBookmarksBrowserTest.prototype = { 18 MaterialBookmarksBrowserTest.prototype = {
17 __proto__: PolymerTest.prototype, 19 __proto__: PolymerTest.prototype,
18 20
19 browsePreload: 'chrome://bookmarks', 21 browsePreload: 'chrome://bookmarks',
20 22
21 commandLineSwitches: [{switchName: 'enable-features', 23 commandLineSwitches: [{switchName: 'enable-features',
22 switchValue: 'MaterialDesignBookmarks'}], 24 switchValue: 'MaterialDesignBookmarks'}],
23 25
26 typedefCppFixture: 'MdBookmarksBrowserTest',
27
24 extraLibraries: PolymerTest.getLibraries(ROOT_PATH).concat([ 28 extraLibraries: PolymerTest.getLibraries(ROOT_PATH).concat([
25 'test_command_manager.js', 29 'test_command_manager.js',
26 'test_store.js', 30 'test_store.js',
27 'test_util.js', 31 'test_util.js',
28 ]), 32 ]),
29 }; 33 };
30 34
31 function MaterialBookmarksActionsTest() {} 35 function MaterialBookmarksActionsTest() {}
32 36
33 MaterialBookmarksActionsTest.prototype = { 37 MaterialBookmarksActionsTest.prototype = {
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after
161 165
162 extraLibraries: MaterialBookmarksBrowserTest.prototype.extraLibraries.concat([ 166 extraLibraries: MaterialBookmarksBrowserTest.prototype.extraLibraries.concat([
163 'folder_node_test.js', 167 'folder_node_test.js',
164 ]), 168 ]),
165 }; 169 };
166 170
167 TEST_F('MaterialBookmarksFolderNodeTest', 'All', function() { 171 TEST_F('MaterialBookmarksFolderNodeTest', 'All', function() {
168 mocha.run(); 172 mocha.run();
169 }); 173 });
170 174
175 function MaterialBookmarksPolicyTest() {}
176
177 MaterialBookmarksPolicyTest.prototype = {
178 __proto__: MaterialBookmarksBrowserTest.prototype,
179
180 testGenPreamble: function() {
181 GEN('SetIncognitoAvailability(IncognitoModePrefs::DISABLED);');
182 },
183
184 extraLibraries: MaterialBookmarksBrowserTest.prototype.extraLibraries.concat([
185 'policy_test.js',
186 ]),
187 };
188
189 TEST_F('MaterialBookmarksPolicyTest', 'All', function() {
190 mocha.run();
191 });
192
171 function MaterialBookmarksStoreClientTest() {} 193 function MaterialBookmarksStoreClientTest() {}
172 194
173 MaterialBookmarksStoreClientTest.prototype = { 195 MaterialBookmarksStoreClientTest.prototype = {
174 __proto__: MaterialBookmarksBrowserTest.prototype, 196 __proto__: MaterialBookmarksBrowserTest.prototype,
175 197
176 extraLibraries: MaterialBookmarksBrowserTest.prototype.extraLibraries.concat([ 198 extraLibraries: MaterialBookmarksBrowserTest.prototype.extraLibraries.concat([
177 'store_client_test.js', 199 'store_client_test.js',
178 ]), 200 ]),
179 }; 201 };
180 202
(...skipping 21 matching lines...) Expand all
202 __proto__: MaterialBookmarksBrowserTest.prototype, 224 __proto__: MaterialBookmarksBrowserTest.prototype,
203 225
204 extraLibraries: MaterialBookmarksBrowserTest.prototype.extraLibraries.concat([ 226 extraLibraries: MaterialBookmarksBrowserTest.prototype.extraLibraries.concat([
205 'util_test.js', 227 'util_test.js',
206 ]), 228 ]),
207 }; 229 };
208 230
209 TEST_F('MaterialBookmarksUtilTest', 'All', function() { 231 TEST_F('MaterialBookmarksUtilTest', 'All', function() {
210 mocha.run(); 232 mocha.run();
211 }); 233 });
OLDNEW
« no previous file with comments | « chrome/test/BUILD.gn ('k') | chrome/test/data/webui/md_bookmarks/policy_test.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698