blob: 7fe1bf6515289152c5bd2f12883e04458caa4c59 [file] [log] [blame] [edit]
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
<head>
<script src="../resources/accessibility-helper.js"></script>
<script src="../resources/js-test.js"></script>
</head>
<body>
<div role="generic" id="explicit-generic" style="width: 300px; height: 300px; background-color: yellow;"></div>
<div id="implicit-generic" style="width: 300px; height: 300px; background-color: yellow;"></div>
<script>
var output = "This test ensures the generic ARIA role is exposed correctly.\n\n";
if (window.accessibilityController) {
// Non-hidden, explicit role="generic" elements should not be ignored.
output += expect("accessibilityController.accessibleElementById('explicit-generic').isIgnored", "false");
// Implicit generic elements should be ignored.
var implicitGenericDiv = accessibilityController.accessibleElementById("implicit-generic");
output += expect("!implicitGenericDiv || implicitGenericDiv.isIgnored", "true");
debug(output);
finishJSTest();
}
</script>
</body>
</html>