| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 // Include test fixture. | 5 // Include test fixture. |
| 6 GEN_INCLUDE(['../../testing/chromevox_next_e2e_test_base.js', | 6 GEN_INCLUDE(['../../testing/chromevox_next_e2e_test_base.js', |
| 7 '../../testing/assert_additions.js']); | 7 '../../testing/assert_additions.js']); |
| 8 | 8 |
| 9 GEN_INCLUDE(['../../testing/mock_feedback.js']); | 9 GEN_INCLUDE(['../../testing/mock_feedback.js']); |
| 10 | 10 |
| (...skipping 626 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 637 isChecked = !isChecked; | 637 isChecked = !isChecked; |
| 638 }); | 638 }); |
| 639 </script> | 639 </script> |
| 640 */}, function(root) { | 640 */}, function(root) { |
| 641 var cbx = root.find({role: RoleType.checkBox}); | 641 var cbx = root.find({role: RoleType.checkBox}); |
| 642 var click = cbx.doDefault.bind(cbx); | 642 var click = cbx.doDefault.bind(cbx); |
| 643 var focus = cbx.focus.bind(cbx); | 643 var focus = cbx.focus.bind(cbx); |
| 644 mockFeedback.call(focus) | 644 mockFeedback.call(focus) |
| 645 .expectSpeech('go') | 645 .expectSpeech('go') |
| 646 .expectSpeech('Check box') | 646 .expectSpeech('Check box') |
| 647 .expectSpeech('not checked') | 647 .expectSpeech('Not checked') |
| 648 .call(click) | 648 .call(click) |
| 649 .expectSpeech('go') | 649 .expectSpeech('go') |
| 650 .expectSpeech('Check box') | 650 .expectSpeech('Check box') |
| 651 .expectSpeech('checked') | 651 .expectSpeech('Checked') |
| 652 .call(click) | 652 .call(click) |
| 653 .expectSpeech('go') | 653 .expectSpeech('go') |
| 654 .expectSpeech('Check box') | 654 .expectSpeech('Check box') |
| 655 .expectSpeech('not checked') | 655 .expectSpeech('Not checked') |
| 656 .replay(); | 656 .replay(); |
| 657 }); | 657 }); |
| 658 }); | 658 }); |
| 659 | 659 |
| 660 /** Tests navigating into and out of iframes using nextButton */ | 660 /** Tests navigating into and out of iframes using nextButton */ |
| 661 TEST_F('BackgroundTest', 'ForwardNavigationThroughIframeButtons', function() { | 661 TEST_F('BackgroundTest', 'ForwardNavigationThroughIframeButtons', function() { |
| 662 var mockFeedback = this.createMockFeedback(); | 662 var mockFeedback = this.createMockFeedback(); |
| 663 | 663 |
| 664 var running = false; | 664 var running = false; |
| 665 var runTestIfIframeIsLoaded = function(rootNode) { | 665 var runTestIfIframeIsLoaded = function(rootNode) { |
| (...skipping 503 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1169 <input type="text"></input> | 1169 <input type="text"></input> |
| 1170 */}, function(root) { | 1170 */}, function(root) { |
| 1171 this.listenOnce(root, 'focus', function(e) { | 1171 this.listenOnce(root, 'focus', function(e) { |
| 1172 var focus = ChromeVoxState.instance.currentRange.start.node; | 1172 var focus = ChromeVoxState.instance.currentRange.start.node; |
| 1173 assertEquals(RoleType.textField, focus.role); | 1173 assertEquals(RoleType.textField, focus.role); |
| 1174 assertTrue(focus.state.focused); | 1174 assertTrue(focus.state.focused); |
| 1175 }); | 1175 }); |
| 1176 doCmd('nextEditText')(); | 1176 doCmd('nextEditText')(); |
| 1177 }); | 1177 }); |
| 1178 }); | 1178 }); |
| OLD | NEW |