Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(188)

Side by Side Diff: chrome/browser/resources/chromeos/chromevox/cvox2/background/output_test.extjs

Issue 2052783002: Accessibility objects with layers shouldn't be ignored (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix ChromeVox test Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/modules/accessibility/AXLayoutObject.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 194 matching lines...) Expand 10 before | Expand all | Expand 10 after
205 checkBrailleOutput( 205 checkBrailleOutput(
206 'b h1', 206 'b h1',
207 [{value: new Output.NodeSpan(el), start: 0, end: 4}], 207 [{value: new Output.NodeSpan(el), start: 0, end: 4}],
208 o); 208 o);
209 }); 209 });
210 }); 210 });
211 211
212 TEST_F('OutputE2ETest', 'Audio', function() { 212 TEST_F('OutputE2ETest', 'Audio', function() {
213 this.runWithLoadedTree('<audio src="foo.mp3" controls></audio>', 213 this.runWithLoadedTree('<audio src="foo.mp3" controls></audio>',
214 function(root) { 214 function(root) {
215 var el = root.firstChild.firstChild.firstChild.firstChild; 215 var el = root.find({role: 'button'});
216 var range = cursors.Range.fromNode(el); 216 var range = cursors.Range.fromNode(el);
217 var o = new Output().withSpeechAndBraille(range, null, 'navigate'); 217 var o = new Output().withSpeechAndBraille(range, null, 'navigate');
218 218
219 checkSpeechOutput('play|Button|begin playback|audio|Tool bar', 219 checkSpeechOutput('play|Button|begin playback|audio|Tool bar',
220 [ 220 [
221 {value: new Output.EarconAction('BUTTON'), start: 0, end: 4}, 221 {value: new Output.EarconAction('BUTTON'), start: 0, end: 4},
222 {value: 'description', start: 12, end: 26}, 222 {value: 'description', start: 12, end: 26},
223 {value: 'name', start: 27, end: 32}, 223 {value: 'name', start: 27, end: 32},
224 {value: 'role', start: 33, end: 41} 224 {value: 'role', start: 33, end: 41}
225 ], 225 ],
(...skipping 419 matching lines...) Expand 10 before | Expand all | Expand 10 after
645 this.runWithLoadedTree(function() {/*! 645 this.runWithLoadedTree(function() {/*!
646 <div><button>ok</button></div> 646 <div><button>ok</button></div>
647 */}, 647 */},
648 function(root) { 648 function(root) {
649 var div = root.find({role: 'div'}); 649 var div = root.find({role: 'div'});
650 var o = new Output().withSpeech(cursors.Range.fromNode(div)); 650 var o = new Output().withSpeech(cursors.Range.fromNode(div));
651 assertEquals('ok|Button' 651 assertEquals('ok|Button'
652 , o.speechOutputForTest.string_); 652 , o.speechOutputForTest.string_);
653 }); 653 });
654 }); 654 });
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/modules/accessibility/AXLayoutObject.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698