blob: c05955298cf5dcf685eb10d38f0e15449c05a38e [file] [log] [blame]
<html>
<head>
<script src="../../resources/js-test.js"></script>
</head>
<body id="body">
<p>This tests the accessibility roles of multiselect elements and their option
elements.</p>
<p id="console"></p>
<p id="notDRT">This test should only be run inside of DumpRenderTree.</p>
<select id="selectElement" multiple title="selectElement">
<option SELECTED>Option 1</option>
<option>Option 2</option>
<option>Option 3</option>
</select>
<script>
if (window.testRunner && window.accessibilityController) {
document.getElementById("notDRT").style.visibility = "hidden";
document.getElementById("selectElement").focus();
shouldBe('accessibilityController.focusedElement.role', '"AXRole: AXList"');
shouldBe('accessibilityController.focusedElement.childAtIndex(0).role', '"AXRole: AXStaticText"');
}
</script>
</body>
</html>