| 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 autofill options WebUI testing. | 6 * TestFixture for autofill options WebUI testing. |
| 7 * @extends {testing.Test} | 7 * @extends {testing.Test} |
| 8 * @constructor | 8 * @constructor |
| 9 **/ | 9 */ |
| 10 function AutofillOptionsWebUITest() {} | 10 function AutofillOptionsWebUITest() {} |
| 11 | 11 |
| 12 AutofillOptionsWebUITest.prototype = { | 12 AutofillOptionsWebUITest.prototype = { |
| 13 __proto__: testing.Test.prototype, | 13 __proto__: testing.Test.prototype, |
| 14 | 14 |
| 15 /** | 15 /** |
| 16 * Browse to autofill options. | 16 * Browse to autofill options. |
| 17 **/ | 17 */ |
| 18 browsePreload: 'chrome://settings-frame/autofill', | 18 browsePreload: 'chrome://settings-frame/autofill', |
| 19 }; | 19 }; |
| 20 | 20 |
| 21 // Test opening the autofill options has correct location. | 21 // Test opening the autofill options has correct location. |
| 22 TEST_F('AutofillOptionsWebUITest', 'testOpenAutofillOptions', function() { | 22 TEST_F('AutofillOptionsWebUITest', 'testOpenAutofillOptions', function() { |
| 23 assertEquals(this.browsePreload, document.location.href); | 23 assertEquals(this.browsePreload, document.location.href); |
| 24 }); | 24 }); |
| 25 | 25 |
| 26 /** | 26 /** |
| 27 * TestFixture for autofill edit address overlay WebUI testing. | 27 * TestFixture for autofill edit address overlay WebUI testing. |
| 28 * @extends {testing.Test} | 28 * @extends {testing.Test} |
| 29 * @constructor | 29 * @constructor |
| 30 */ | 30 */ |
| 31 function AutofillEditAddressWebUITest() {} | 31 function AutofillEditAddressWebUITest() {} |
| 32 | 32 |
| 33 AutofillEditAddressWebUITest.prototype = { | 33 AutofillEditAddressWebUITest.prototype = { |
| 34 __proto__: testing.Test.prototype, | 34 __proto__: testing.Test.prototype, |
| 35 | 35 |
| 36 /** | 36 /** |
| 37 * Browse to autofill edit address overlay. | 37 * Browse to autofill edit address overlay. |
| 38 **/ | 38 */ |
| 39 browsePreload: 'chrome://settings-frame/autofillEditAddress', | 39 browsePreload: 'chrome://settings-frame/autofillEditAddress', |
| 40 | 40 |
| 41 /** @inheritDoc */ | 41 /** @inheritDoc */ |
| 42 isAsync: true, | 42 isAsync: true, |
| 43 | 43 |
| 44 /** | 44 /** |
| 45 * TODO(tkent): Fix an accessibility error. | 45 * TODO(tkent): Fix an accessibility error. |
| 46 */ | 46 */ |
| 47 runAccessibilityChecks: false, | 47 runAccessibilityChecks: false, |
| 48 }; | 48 }; |
| (...skipping 10 matching lines...) Expand all Loading... |
| 59 var input = phoneList.querySelector('input'); | 59 var input = phoneList.querySelector('input'); |
| 60 input.focus(); | 60 input.focus(); |
| 61 document.execCommand('insertText', false, '111-222-333'); | 61 document.execCommand('insertText', false, '111-222-333'); |
| 62 assertEquals('111-222-333', input.value); | 62 assertEquals('111-222-333', input.value); |
| 63 input.blur(); | 63 input.blur(); |
| 64 phoneList.doneValidating().then(function() { | 64 phoneList.doneValidating().then(function() { |
| 65 testDone(); | 65 testDone(); |
| 66 }); | 66 }); |
| 67 }); | 67 }); |
| 68 }); | 68 }); |
| OLD | NEW |