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

Side by Side Diff: third_party/WebKit/LayoutTests/accessibility/nochildren-elements.html

Issue 2893683002: Selection follows focus/activedescendant in single selection containers (Closed)
Patch Set: Last test to fix we hope Created 3 years, 7 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
OLDNEW
1 <html> 1 <html>
2 <script> 2 <script>
3 if (window.testRunner) 3 if (window.testRunner)
4 testRunner.dumpAsText(); 4 testRunner.dumpAsText();
5 </script> 5 </script>
6 <body id='body'> 6 <body id='body'>
7 7
8 8
9 <!-- This test makes sure that these types of elements DO NOT have children. 9 <!-- This test makes sure that these types of elements DO NOT have children.
10 The test will pass if attributesOfChildren() returns nil --> 10 The test will pass if attributesOfChildren() returns nil -->
11 11
12 <input id="file" type="file"> 12 <input id="file" type="file">
13 <div id="button" role="button"><b><i>inside</i></b></div> 13 <div id="button" role="button"><b><i>inside</i></b></div>
14 <div id="button-w-popup" role="button" aria-haspopup="true"><b><i>inside</i> </b></div>
14 15
15 <div id="result"></div> 16 <div id="result"></div>
16 17
17 18
18 <script> 19 <script>
19 if (window.accessibilityController) { 20 if (window.accessibilityController) {
20 var result = document.getElementById("result"); 21 var result = document.getElementById("result");
21 22
22 var element1 = accessibilityController.accessibleElementById("file") ; 23 var element1 = accessibilityController.accessibleElementById("file") ;
23
24 var element2 = accessibilityController.accessibleElementById("button "); 24 var element2 = accessibilityController.accessibleElementById("button ");
25 var element3 = accessibilityController.accessibleElementById("button -w-popup");
25 26
26 var element1Children = element1.attributesOfChildren(); 27 var element1Children = element1.attributesOfChildren();
27 var element2Children = element2.attributesOfChildren(); 28 var element2Children = element2.attributesOfChildren();
29 var element3Children = element3.attributesOfChildren();
28 30
29 if (element1Children != "" || element2Children != "") { 31 if (element1Children != "" || element2Children != "" || element3Chil dren != "") {
30 result.innerText += "FAIL\n" + element1Children + "\n" + element2 Children; 32 result.innerText += "FAIL\n" + element1Children + "\n" + element2 Children + "\n" + element3Children;
31 } 33 }
32 else { 34 else {
33 result.innerText += "PASS"; 35 result.innerText += "PASS";
34 } 36 }
35 } 37 }
36 </script> 38 </script>
37 </body> 39 </body>
38 </html> 40 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698