Index: LayoutTests/fast/forms/radio/radio-group-arrow-cycle-edge.html |
diff --git a/LayoutTests/fast/forms/radio/radio-group-arrow-cycle-edge.html b/LayoutTests/fast/forms/radio/radio-group-arrow-cycle-edge.html |
new file mode 100644 |
index 0000000000000000000000000000000000000000..5d1cd5e990917913ddc14c40e47a0998243a8c26 |
--- /dev/null |
+++ b/LayoutTests/fast/forms/radio/radio-group-arrow-cycle-edge.html |
@@ -0,0 +1,54 @@ |
+<!DOCTYPE html> |
+ |
+<body> |
+<script src="../resources/common.js"></script> |
+ |
+<script src="../../../resources/js-test.js"></script> |
+ |
+<form name=alpha> |
+<input type="radio" name="fruit" id="apple"><br> |
+<input type="radio" name="fruit" id="banana"><br> |
+<input type="radio" name="fruit" id="cherry"><br> |
+<input type="radio" name="fruit" form=beta id="tomato"><br> |
+<input type="radio" name="fruit" form=beta id="delta"><br> |
+</form> |
+<form name=beta> |
+ <input type="radio" name="fruit" id="pumpkin"><br> |
+</form> |
+<input type="radio" name="fruit" form=alpha id="cucumber"><br> |
+ |
+<script> |
+document.alpha.insertBefore(document.beta, document.alpha.fruit[2]); |
+description('Tests after pressing last radio button in the list, on pressing downkey it selects back first radio button'); |
+ |
+clickElement(document.getElementById('cherry')); |
+shouldBeTrue('document.getElementById("cherry").checked'); |
+ |
+eventSender.keyDown('downArrow'); |
+shouldBeTrue('document.getElementById("apple").checked'); |
+ |
+eventSender.keyDown('upArrow'); |
+shouldBeTrue('document.getElementById("cherry").checked'); |
+ |
+ |
+clickElement(document.getElementById('cucumber')); |
+shouldBeTrue('document.getElementById("cucumber").checked'); |
+ |
+eventSender.keyDown('downArrow'); |
+shouldBeTrue('document.getElementById("tomato").checked'); |
+ |
+eventSender.keyDown('upArrow'); |
+shouldBeTrue('document.getElementById("cucumber").checked'); |
+ |
+clickElement(document.getElementById('pumpkin')); |
+shouldBeTrue('document.getElementById("pumpkin").checked'); |
+ |
+eventSender.keyDown('downArrow'); |
+shouldBeTrue('document.getElementById("pumpkin").checked'); |
+ |
+eventSender.keyDown('upArrow'); |
+shouldBeTrue('document.getElementById("pumpkin").checked'); |
+ |
+</script> |
+</body> |
+</html> |