Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / accessibility / ignore-spacer-elements.html
blob60ef23c019145ff177f09d237ea46586511805c5
1 <html>
2 <script>
3 if (window.testRunner)
4 testRunner.dumpAsText();
5 </script>
6 <body id="body">
8 <!-- This test makes sure that spacer elements are not returned as elements. There should be at most 4 elements returned -->
10 <b>First</b>
11 <b>Second</b>
12 <a href="http://www.apple.com">Apple</a>
13 <a href="http://www.yahoo.com">Yahoo</a>
16 <div id="result"></div>
19 <script>
20 if (window.accessibilityController) {
21 var result = document.getElementById("result");
23 var body = document.getElementById("body");
24 body.focus();
25 var container = accessibilityController.focusedElement.childAtIndex(0);
27 // The Gtk port ATs expect the bold inline text to not have accessible objects.
28 var expectedCount = (testRunner.platformName == "gtk") ? 2 : 4;
29 if (container.childrenCount == expectedCount) {
30 result.innerText += "Test passed\n";
32 else {
33 result.innerText += "Test failed\n";
36 </script>
37 </body>
38 </html>