blob: 720883d3be302d9fe20b5e4a3b30dcfb5e60854f [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
<head>
<script src="../../resources/js-test-pre.js"></script>
</head>
<body id="body">
<input type='text' name='foo' value='foo bar baz' />
<input type='password' name='bar' value='foo bar baz' />
<p id="description"></p>
<div id="console"></div>
<script>
description("This tests the ability to get element text for a specified range.");
if (window.accessibilityController) {
document.getElementById("body").focus();
var webArea = accessibilityController.focusedElement;
var panel = webArea.childAtIndex(0);
var entry = panel.childAtIndex(0);
var password = panel.childAtIndex(1);
shouldBe("entry.stringForRange(0, -1)", "'foo bar baz'");
shouldBe("password.stringForRange(0, -1)", "'\342\200\242\342\200\242\342\200\242\342\200\242\342\200\242\342\200\242\342\200\242\342\200\242\342\200\242\342\200\242\342\200\242'");
}
</script>
<script src="../../resources/js-test-post.js"></script>
</body>
</html>