| 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 GEN_INCLUDE(['../../testing/assert_additions.js']); | 5 GEN_INCLUDE(['../../testing/assert_additions.js']); |
| 6 GEN_INCLUDE(['../../testing/chromevox_next_e2e_test_base.js']); | 6 GEN_INCLUDE(['../../testing/chromevox_next_e2e_test_base.js']); |
| 7 | 7 |
| 8 /** | 8 /** |
| 9 * Gets the braille output and asserts that it matches expected values. | 9 * Gets the braille output and asserts that it matches expected values. |
| 10 * Annotations in the output that are primitive strings are ignored. | 10 * Annotations in the output that are primitive strings are ignored. |
| (...skipping 709 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 720 <div role="slider" aria-valuemin="1" aria-valuemax="10" aria-valuenow="2" | 720 <div role="slider" aria-valuemin="1" aria-valuemax="10" aria-valuenow="2" |
| 721 aria-label="volume"></div> | 721 aria-label="volume"></div> |
| 722 <progress aria-valuemin="1" aria-valuemax="10" | 722 <progress aria-valuemin="1" aria-valuemax="10" |
| 723 aria-valuenow="2" aria-label="volume"></progress> | 723 aria-valuenow="2" aria-label="volume"></progress> |
| 724 <meter aria-valuemin="1" aria-valuemax="10" aria-valuenow="2" | 724 <meter aria-valuemin="1" aria-valuemax="10" aria-valuenow="2" |
| 725 aria-label="volume"></meter> | 725 aria-label="volume"></meter> |
| 726 <div role="spinbutton" aria-valuemin="1" aria-valuemax="10" | 726 <div role="spinbutton" aria-valuemin="1" aria-valuemax="10" |
| 727 aria-valuenow="2" aria-label="volume"></div> | 727 aria-valuenow="2" aria-label="volume"></div> |
| 728 */}, function(root) { | 728 */}, function(root) { |
| 729 | 729 |
| 730 var obj = root.find({role: RoleType.slider}); | 730 var obj = root.find({role: RoleType.SLIDER}); |
| 731 var o = new Output().withSpeech(cursors.Range.fromNode(obj)); | 731 var o = new Output().withSpeech(cursors.Range.fromNode(obj)); |
| 732 checkSpeechOutput('2|Min 1|Max 10|volume|Slider', | 732 checkSpeechOutput('2|Min 1|Max 10|volume|Slider', |
| 733 [ | 733 [ |
| 734 {value: 'valueForRange', start: 0, end: 1}, | 734 {value: 'valueForRange', start: 0, end: 1}, |
| 735 {value: 'name', start: 15,end: 21}, | 735 {value: 'name', start: 15,end: 21}, |
| 736 {value: new Output.EarconAction('SLIDER'), start: 15, end: 21}, | 736 {value: new Output.EarconAction('SLIDER'), start: 15, end: 21}, |
| 737 {value: 'role', start: 22, end: 28} | 737 {value: 'role', start: 22, end: 28} |
| 738 ], | 738 ], |
| 739 o); | 739 o); |
| 740 | 740 |
| 741 obj = root.find({role: RoleType.progressIndicator}); | 741 obj = root.find({role: RoleType.PROGRESS_INDICATOR}); |
| 742 o = new Output().withSpeech(cursors.Range.fromNode(obj)); | 742 o = new Output().withSpeech(cursors.Range.fromNode(obj)); |
| 743 checkSpeechOutput('2|Min 1|Max 10|volume|Progress indicator', | 743 checkSpeechOutput('2|Min 1|Max 10|volume|Progress indicator', |
| 744 [ | 744 [ |
| 745 {value: 'valueForRange', start: 0, end: 1}, | 745 {value: 'valueForRange', start: 0, end: 1}, |
| 746 {value: 'name', start: 15,end: 21}, | 746 {value: 'name', start: 15,end: 21}, |
| 747 {value: 'role', start: 22, end: 40} | 747 {value: 'role', start: 22, end: 40} |
| 748 ], | 748 ], |
| 749 o); | 749 o); |
| 750 | 750 |
| 751 obj = root.find({role: RoleType.meter}); | 751 obj = root.find({role: RoleType.METER}); |
| 752 o = new Output().withSpeech(cursors.Range.fromNode(obj)); | 752 o = new Output().withSpeech(cursors.Range.fromNode(obj)); |
| 753 checkSpeechOutput('2|Min 1|Max 10|volume|Meter', | 753 checkSpeechOutput('2|Min 1|Max 10|volume|Meter', |
| 754 [ | 754 [ |
| 755 {value: 'valueForRange', start: 0, end: 1}, | 755 {value: 'valueForRange', start: 0, end: 1}, |
| 756 {value: 'name', start: 15,end: 21}, | 756 {value: 'name', start: 15,end: 21}, |
| 757 {value: 'role', start: 22, end: 27} | 757 {value: 'role', start: 22, end: 27} |
| 758 ], | 758 ], |
| 759 o); | 759 o); |
| 760 | 760 |
| 761 obj = root.find({role: RoleType.spinButton}); | 761 obj = root.find({role: RoleType.SPIN_BUTTON}); |
| 762 o = new Output().withSpeech(cursors.Range.fromNode(obj)); | 762 o = new Output().withSpeech(cursors.Range.fromNode(obj)); |
| 763 checkSpeechOutput('2|Min 1|Max 10|volume|Spin button', | 763 checkSpeechOutput('2|Min 1|Max 10|volume|Spin button', |
| 764 [ | 764 [ |
| 765 {value: 'valueForRange', start: 0, end: 1}, | 765 {value: 'valueForRange', start: 0, end: 1}, |
| 766 {value: 'name', start: 15,end: 21}, | 766 {value: 'name', start: 15,end: 21}, |
| 767 {value: new Output.EarconAction('LISTBOX'), start: 15, end: 21}, | 767 {value: new Output.EarconAction('LISTBOX'), start: 15, end: 21}, |
| 768 {value: 'role', start: 22, end: 33} | 768 {value: 'role', start: 22, end: 33} |
| 769 ], | 769 ], |
| 770 o); | 770 o); |
| 771 }); | 771 }); |
| 772 }); | 772 }); |
| OLD | NEW |