OLD | NEW |
---|---|
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 Suite of tests for site-list. */ | 5 /** @fileoverview Suite of tests for site-list. */ |
6 cr.define('site_list', function() { | 6 cr.define('site_list', function() { |
7 function registerTests() { | 7 function registerTests() { |
8 suite('SiteList', function() { | 8 suite('SiteList', function() { |
9 /** | 9 /** |
10 * A site list element created before each test. | 10 * A site list element created before each test. |
(...skipping 232 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
243 setting: 'session_only', | 243 setting: 'session_only', |
244 source: 'preference', | 244 source: 'preference', |
245 }, | 245 }, |
246 ] | 246 ] |
247 } | 247 } |
248 }; | 248 }; |
249 | 249 |
250 // Import necessary html before running suite. | 250 // Import necessary html before running suite. |
251 suiteSetup(function() { | 251 suiteSetup(function() { |
252 CrSettingsPrefs.setInitialized(); | 252 CrSettingsPrefs.setInitialized(); |
253 // Add a no-op stub to catch navigations during the test. | |
254 settings.navigateTo = function(route) {}; | |
Dan Beam
2016/07/23 00:17:12
i haz a sad :_(
tommycli
2016/07/25 16:47:21
Yeah this is unfortunate. This will be gone when s
| |
253 return PolymerTest.importHtml( | 255 return PolymerTest.importHtml( |
254 'chrome://md-settings/site_settings/site_list.html'); | 256 'chrome://md-settings/site_settings/site_list.html'); |
255 }); | 257 }); |
256 | 258 |
257 suiteTeardown(function() { | 259 suiteTeardown(function() { |
258 CrSettingsPrefs.resetForTesting(); | 260 CrSettingsPrefs.resetForTesting(); |
259 }); | 261 }); |
260 | 262 |
261 // Initialize a site-list before each test. | 263 // Initialize a site-list before each test. |
262 setup(function() { | 264 setup(function() { |
(...skipping 377 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
640 function(contentType) { | 642 function(contentType) { |
641 // No further checks needed. If this fails, it will hang the test. | 643 // No further checks needed. If this fails, it will hang the test. |
642 }); | 644 }); |
643 }); | 645 }); |
644 }); | 646 }); |
645 } | 647 } |
646 return { | 648 return { |
647 registerTests: registerTests, | 649 registerTests: registerTests, |
648 }; | 650 }; |
649 }); | 651 }); |
OLD | NEW |