haikuwebkit/LayoutTests/accessibility/win/multiple-select-element-rol...

32 lines
882 B
HTML

<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>