| 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 Runs the Polymer Settings tests. */ | 5 /** @fileoverview Runs the Polymer Settings tests. */ |
| 6 | 6 |
| 7 /** @const {string} Path to source root. */ | 7 /** @const {string} Path to source root. */ |
| 8 var ROOT_PATH = '../../../../../'; | 8 var ROOT_PATH = '../../../../../'; |
| 9 | 9 |
| 10 // Polymer BrowserTest fixture. | 10 // Polymer BrowserTest fixture. |
| (...skipping 962 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 973 TEST_F('CrSettingsNonExistentRouteTest', 'All', function() { | 973 TEST_F('CrSettingsNonExistentRouteTest', 'All', function() { |
| 974 suite('NonExistentRoutes', function() { | 974 suite('NonExistentRoutes', function() { |
| 975 test('redirect to basic', function() { | 975 test('redirect to basic', function() { |
| 976 assertEquals(settings.Route.BASIC, settings.getCurrentRoute()); | 976 assertEquals(settings.Route.BASIC, settings.getCurrentRoute()); |
| 977 assertEquals('/', location.pathname); | 977 assertEquals('/', location.pathname); |
| 978 }); | 978 }); |
| 979 }); | 979 }); |
| 980 mocha.run(); | 980 mocha.run(); |
| 981 }); | 981 }); |
| 982 | 982 |
| 983 // Hangs on ASAN builder for unknown reasons. TODO(michaelpg): Find reason. | |
| 984 GEN('#if defined(ADDRESS_SANITIZER)'); | |
| 985 GEN('#define MAYBE_All DISABLED_All'); | |
| 986 GEN('#else'); | |
| 987 GEN('#define MAYBE_All All'); | |
| 988 GEN('#endif'); | |
| 989 | |
| 990 /** | 983 /** |
| 991 * @constructor | 984 * @constructor |
| 992 * @extends {SettingsPageBrowserTest} | 985 * @extends {SettingsPageBrowserTest} |
| 993 */ | 986 */ |
| 994 function CrSettingsRouteDynamicParametersTest() {} | 987 function CrSettingsRouteDynamicParametersTest() {} |
| 995 | 988 |
| 996 CrSettingsRouteDynamicParametersTest.prototype = { | 989 CrSettingsRouteDynamicParametersTest.prototype = { |
| 997 __proto__: CrSettingsBrowserTest.prototype, | 990 __proto__: CrSettingsBrowserTest.prototype, |
| 998 | 991 |
| 999 /** @override */ | 992 /** @override */ |
| 1000 browsePreload: 'chrome://md-settings/people?guid=a%2Fb&foo=42', | 993 browsePreload: 'chrome://md-settings/people?guid=a%2Fb&foo=42', |
| 1001 | 994 |
| 1002 /** @override */ | 995 /** @override */ |
| 1003 runAccessibilityChecks: false, | 996 runAccessibilityChecks: false, |
| 1004 }; | 997 }; |
| 1005 | 998 |
| 1006 TEST_F('CrSettingsRouteDynamicParametersTest', 'MAYBE_All', function() { | 999 TEST_F('CrSettingsRouteDynamicParametersTest', 'All', function() { |
| 1007 suite('DynamicParameters', function() { | 1000 suite('DynamicParameters', function() { |
| 1008 test('get parameters from URL and navigation', function(done) { | 1001 test('get parameters from URL and navigation', function(done) { |
| 1009 assertEquals(settings.Route.PEOPLE, settings.getCurrentRoute()); | 1002 assertEquals(settings.Route.PEOPLE, settings.getCurrentRoute()); |
| 1010 assertEquals('a/b', settings.getQueryParameters().get('guid')); | 1003 assertEquals('a/b', settings.getQueryParameters().get('guid')); |
| 1011 assertEquals('42', settings.getQueryParameters().get('foo')); | 1004 assertEquals('42', settings.getQueryParameters().get('foo')); |
| 1012 | 1005 |
| 1013 var params = new URLSearchParams(); | 1006 var params = new URLSearchParams(); |
| 1014 params.set('bar', 'b=z'); | 1007 params.set('bar', 'b=z'); |
| 1015 params.set('biz', '3'); | 1008 params.set('biz', '3'); |
| 1016 settings.navigateTo(settings.Route.SYNC, params); | 1009 settings.navigateTo(settings.Route.SYNC, params); |
| (...skipping 240 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1257 extraLibraries: CrSettingsBrowserTest.prototype.extraLibraries.concat([ | 1250 extraLibraries: CrSettingsBrowserTest.prototype.extraLibraries.concat([ |
| 1258 'test_browser_proxy.js', | 1251 'test_browser_proxy.js', |
| 1259 'test_extension_control_browser_proxy.js', | 1252 'test_extension_control_browser_proxy.js', |
| 1260 'extension_controlled_indicator_tests.js', | 1253 'extension_controlled_indicator_tests.js', |
| 1261 ]), | 1254 ]), |
| 1262 }; | 1255 }; |
| 1263 | 1256 |
| 1264 TEST_F('CrSettingsExtensionControlledIndicatorTest', 'All', function() { | 1257 TEST_F('CrSettingsExtensionControlledIndicatorTest', 'All', function() { |
| 1265 mocha.run(); | 1258 mocha.run(); |
| 1266 }); | 1259 }); |
| OLD | NEW |