blob: cb90d01c94f9ed1b3a06abbe37fd54dc579942b5 [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
<head>
<script src="../../resources/js-test-pre.js"></script>
<script>
function dumpAccessibilityChildren(element, level) {
if (element.stringValue.indexOf('End of test') >= 0)
return false;
var indent = "";
for (var k = 0; k < level; k++) { indent += " "; }
debug(indent + element.role + " " + element.stringValue);
var childrenCount = element.childrenCount;
for (var k = 0; k < childrenCount; k++) {
if (!dumpAccessibilityChildren(element.childAtIndex(k), level+1))
return false;
}
return true;
}
</script>
<style>
p::first-letter {
font-size: 200%;
}
</style>
</head>
<body id="body">
<div>
<p id="text">Test text</p>
</div>
<p id="description"></p>
<div id="console"></div>
<script>
if (window.accessibilityController) {
description("This tests that we are adding children correctly when having CSS first-letter selector.");
var content = accessibilityController.accessibleElementById("text");
dumpAccessibilityChildren(content, 0);
shouldBe("content.childrenCount", "1");
}
successfullyParsed = true;
</script>
<script src="../../resources/js-test-post.js"></script>
</body>
</html>