Refactoring: Pull all fullscreen code out of Document and into its own helper class
[WebKit-https.git] / LayoutTests / accessibility / aria-text-role.html
1 <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
2 <html>
3 <head>
4 <script src="../resources/js-test-pre.js"></script>
5 <script src="../resources/accessibility-helper.js"></script>
6 </head>
7 <body id="body">
8
9 <div id="textrole" tabindex=0 role="text" aria-label="all at once">
10 <b>hello world</b>
11 <i>this is a test</i>
12 <a href="#">more test</a>
13 </div>
14
15 <p id="description"></p>
16 <div id="console"></div>
17
18 <script>
19
20     description("This tests that you can set an ARIA text role and that it will not have children through hit testing");
21
22     if (window.accessibilityController) {
23
24         document.getElementById("textrole").focus();
25         var textrole = accessibilityController.focusedElement;
26         shouldBe("textrole.role", "platformRoleForStaticText(textrole)");
27         shouldBe("textrole.stringValue", "'AXValue: all at once'");
28
29         // now check the hit-testing
30         var x = textrole.clickPointX;
31         var y = textrole.clickPointY;
32         shouldBe("textrole.elementAtPoint(x, y).isEqual(textrole)", "true");
33     }
34
35 </script>
36
37 <script src="../resources/js-test-post.js"></script>
38 </body>
39 </html>