blob: c59cc1cf9c8b085496f8123a6c63e5b9f5b7f4ec [file] [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>
<input type="image" role="checkbox" aria-checked="true" id="aria-checked-true-checkbox">check1<BR>
<input type="image" role="checkbox" aria-checked="false" id="aria-checked-false-checkbox">check2<BR>
<input type="image" role="checkbox" aria-checked="mixed" id="aria-checked-mixed-checkbox">check3<BR>
<input type="image" role="checkbox" id="aria-checked-missing-checkbox">check4<BR>
<script>
var testOutput = "This tests that input types masquerading as checkboxes will use the aria-checked values for its value.\n\n";
if (window.accessibilityController) {
testOutput += expect("accessibilityController.accessibleElementById('aria-checked-true-checkbox').intValue", "1");
testOutput += expect("accessibilityController.accessibleElementById('aria-checked-false-checkbox').intValue", "0");
testOutput += expect("accessibilityController.accessibleElementById('aria-checked-mixed-checkbox').intValue", "2");
testOutput += expect("accessibilityController.accessibleElementById('aria-checked-missing-checkbox').intValue", "0");
debug(testOutput);
}
</script>
</body>
</html>