blob: 6ddc2cd3839a833c3855c3cc9e2f0864cdfd2a05 [file]
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
<head>
<script>
function buildAccessibilityTree(accessibilityObject, indent) {
var str = "";
for (var i = 0; i < indent; i++)
str += " ";
str += accessibilityObject.role;
str += " " + accessibilityObject.stringValue;
str += "\n";
document.getElementById("tree").innerText += str;
if (accessibilityObject.stringValue.indexOf('End of test') >= 0)
return false;
var count = accessibilityObject.childrenCount;
for (var i = 0; i < count; ++i) {
if (!buildAccessibilityTree(accessibilityObject.childAtIndex(i), indent + 1))
return false;
}
return true;
}
</script>
<script src="../../../fast/js/resources/js-test-pre.js"></script>
</head>
<body>
<p>Paragraph</p>
<button>button</button>
<p></p>
<iframe src="data:text/html,<body>iframe</body>"></iframe>
<p></p>
<textarea>text area</textarea>
<div>
Div
<p></p>
<button>button</button>
</div>
<h3>
Heading
<p></p>
<button>button</button>
<p></p>
<img src="foo" alt="I should be an image" />
</h3>
<div>End of test</div>
<pre id="tree"></pre>
<p id="description"></p>
<div id="console"></div>
<script>
description("This tests that the text associated with replaced objects in an anonymous block is correct.");
if (window.accessibilityController) {
// Build the accessibility tree up until 'End of test' is encountered.
document.body.focus();
buildAccessibilityTree(accessibilityController.focusedElement, 0);
}
</script>
<script src="../../../fast/js/resources/js-test-post.js"></script>
</body>
</html>