| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 * TestFixture for browser options WebUI testing. | 6 * TestFixture for browser options WebUI testing. |
| 7 * @extends {testing.Test} | 7 * @extends {testing.Test} |
| 8 * @constructor | 8 * @constructor |
| 9 */ | 9 */ |
| 10 function BrowserOptionsWebUITest() {} | 10 function BrowserOptionsWebUITest() {} |
| 11 | 11 |
| 12 BrowserOptionsWebUITest.prototype = { | 12 BrowserOptionsWebUITest.prototype = { |
| 13 __proto__: testing.Test.prototype, | 13 __proto__: testing.Test.prototype, |
| 14 | 14 |
| 15 /** @override */ | 15 /** @override */ |
| 16 browsePreload: 'chrome://chrome/settings/', | 16 browsePreload: 'chrome://chrome/settings/', |
| 17 }; | 17 }; |
| 18 | 18 |
| 19 // Test opening the browser options has correct location. | 19 // Test opening the browser options has correct location. |
| 20 // Times out on Mac debug only. See http://crbug.com/121030 | 20 // Times out on Mac debug only. See http://crbug.com/121030 |
| 21 GEN('#if defined(OS_MACOSX) && !defined(NDEBUG)'); | 21 GEN('#if defined(OS_MACOSX) && !defined(NDEBUG)'); |
| 22 GEN('#define MAYBE_testOpenBrowserOptions ' + | 22 GEN('#define MAYBE_testOpenBrowserOptions ' + |
| 23 'DISABLED_testOpenBrowserOptions'); | 23 'DISABLED_testOpenBrowserOptions'); |
| 24 // Flaky on Winxp: http://crbug.com/396752. | |
| 25 GEN('#elif defined(OS_WIN)'); | |
| 26 GEN('#define MAYBE_testOpenBrowserOptions ' + | |
| 27 'DISABLED_testOpenBrowserOptions'); | |
| 28 GEN('#else'); | 24 GEN('#else'); |
| 29 GEN('#define MAYBE_testOpenBrowserOptions testOpenBrowserOptions'); | 25 GEN('#define MAYBE_testOpenBrowserOptions testOpenBrowserOptions'); |
| 30 GEN('#endif // defined(OS_MACOSX)'); | 26 GEN('#endif // defined(OS_MACOSX)'); |
| 31 TEST_F('BrowserOptionsWebUITest', 'MAYBE_testOpenBrowserOptions', function() { | 27 TEST_F('BrowserOptionsWebUITest', 'MAYBE_testOpenBrowserOptions', function() { |
| 32 assertEquals(this.browsePreload, document.location.href); | 28 assertEquals(this.browsePreload, document.location.href); |
| 33 }); | 29 }); |
| 34 | 30 |
| 35 | 31 |
| 36 /** | 32 /** |
| 37 * @extends {testing.Test} | 33 * @extends {testing.Test} |
| (...skipping 25 matching lines...) Expand all Loading... |
| 63 __proto__: testing.Test.prototype, | 59 __proto__: testing.Test.prototype, |
| 64 | 60 |
| 65 /** @override */ | 61 /** @override */ |
| 66 browsePreload: 'chrome://settings-frame/autofill', | 62 browsePreload: 'chrome://settings-frame/autofill', |
| 67 }; | 63 }; |
| 68 | 64 |
| 69 TEST_F('AdvancedSettingsWebUITest', 'testAdvancedSettingsShown', function() { | 65 TEST_F('AdvancedSettingsWebUITest', 'testAdvancedSettingsShown', function() { |
| 70 assertEquals(this.browsePreload, document.location.href); | 66 assertEquals(this.browsePreload, document.location.href); |
| 71 expectFalse($('advanced-settings').hidden); | 67 expectFalse($('advanced-settings').hidden); |
| 72 }); | 68 }); |
| OLD | NEW |