<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
<head>
<script src="../resources/testharness.js"></script>
<script src="../resources/testharnessreport.js"></script>
</head>
<body>
<div id="list" role="list">
<div role="listitem" aria-setSize="10" aria-posinset="3"></div>
<div role="listitem" aria-setSize="10" aria-posinset="5"></div>
</div>
<script>
test(function(t) {
var list = accessibilityController.accessibleElementById("list");
assert_equals(list.childAtIndex(0).posInSet,3);
assert_equals(list.childAtIndex(1).posInSet,5);
assert_equals(list.childAtIndex(0).setSize,10);
assert_equals(list.childAtIndex(1).setSize,10);
}, "Tests that aria-posinset and aria-setSize for a simple list are exposed to accessibility correctly");
</script>
<div id="radiogroup" role="radiogroup">
<hr>
<div id="radio1" role="radio" aria-setSize="3" aria-posinset="2">Radio 1</div>
</div>
<script>
test(function(t){
var radio1 = accessibilityController.accessibleElementById("radio1");
assert_equals(radio1.posInSet,2);
assert_equals(radio1.setSize,3);
},"Tests that aria-posinset and aria-setSize for a radio are exposed to accessibility correctly");
</script>
<p id="description"></p>
<div id="console"></div>
</body>
</html>