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

Side by Side Diff: third_party/WebKit/LayoutTests/accessibility/aria-toggle-button-with-title.html

Issue 1417213006: Switch all LayoutTests to use new AX name calculation (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix canvas-fallback-content-labels-expected.txt Created 5 years, 1 month 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
OLDNEW
1 <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> 1 <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
2 <html> 2 <html>
3 <head> 3 <head>
4 <script src="../resources/js-test.js"></script> 4 <script src="../resources/js-test.js"></script>
5 <script> 5 <script>
6 6
7 function runTest() 7 function runTest()
8 { 8 {
9 if (window.accessibilityController) { 9 if (window.accessibilityController) {
10 10
11 document.getElementById("tbutton").focus(); 11 document.getElementById("tbutton").focus();
12 tbutton1 = accessibilityController.focusedElement; 12 tbutton1 = accessibilityController.focusedElement;
13 debug("Role: " + tbutton1.role); 13 debug("Role: " + tbutton1.role);
14 shouldBe("tbutton1.deprecatedTitle", "'AXTitle: Toggle button'"); 14 shouldBe("tbutton1.name", "'Toggle button'");
15 15
16 document.getElementById("button").focus(); 16 document.getElementById("button").focus();
17 button = accessibilityController.focusedElement; 17 button = accessibilityController.focusedElement;
18 debug("Role: " + button.role); 18 debug("Role: " + button.role);
19 shouldBe("button.deprecatedTitle", "'AXTitle: Button title'"); 19 shouldBe("button.name", "'Button title'");
20 } 20 }
21 } 21 }
22 </script> 22 </script>
23 23
24 </head> 24 </head>
25 <body id="body" onload="runTest()"> 25 <body id="body" onload="runTest()">
26 26
27 <a id="tbutton" tabindex="0" class="button" role="button" aria-pressed="true">To ggle button</a> 27 <a id="tbutton" tabindex="0" class="button" role="button" aria-pressed="true">To ggle button</a>
28 28
29 <div> 29 <div>
30 <button type="button" id="button" role="button"/> 30 <button type="button" id="button" role="button"/>
31 <label>Button title</label> 31 <label>Button title</label>
32 </div> 32 </div>
33 33
34 <p id="description"></p> 34 <p id="description"></p>
35 <div id="console"></div> 35 <div id="console"></div>
36 36
37 <script> 37 <script>
38 description("This tests that a toggle button properly exposes the title when the re isn't a direct relation and textUnderElement is required to be used."); 38 description("This tests that a toggle button properly exposes the title when the re isn't a direct relation and textUnderElement is required to be used.");
39 39
40 </script> 40 </script>
41 </body> 41 </body>
42 </html> 42 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698