AX: no accessibility support for details element
[WebKit-https.git] / LayoutTests / platform / mac / accessibility / details-summary.html
1 <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
2 <html>
3 <head>
4 <script src="../../../resources/js-test-pre.js"></script>
5 </head>
6 <body id="body">
7
8 <details open id="details1">
9   <summary>Some open info</summary>
10   <p>Details about the open topic.</p>
11 </details>
12
13 <details id="details2">
14   <summary>Some open info</summary>
15   <p>Details about the open topic.</p>
16 </details>
17
18 <p id="description"></p>
19 <div id="console"></div>
20
21 <script>
22
23     description("This tests some basic attributes about the details element.");
24
25     if (window.accessibilityController) {
26
27         var details1 = accessibilityController.accessibleElementById("details1");
28         shouldBe("details1.role", "'AXRole: AXGroup'");
29         shouldBe("details1.subrole", "'AXSubrole: AXDetails'");
30         shouldBeTrue("details1.isExpanded");
31         shouldBe("details1.childAtIndex(0).role", "'AXRole: AXGroup'");
32         shouldBe("details1.childAtIndex(0).subrole", "'AXSubrole: AXSummary'");
33
34         var details2 = accessibilityController.accessibleElementById("details2");
35         shouldBe("details2.subrole", "'AXSubrole: AXDetails'");
36         shouldBeFalse("details2.isExpanded");
37     }
38
39 </script>
40
41 <script src="../../../resources/js-test-post.js"></script>
42 </body>
43 </html>