blob: 425a6375ce35529d516dd62bd0e51c00f7f264b7 [file] [log] [blame]
<html>
<head>
<script>
function test()
{
var tf = document.getElementById('tf');
tf.focus();
tf.setSelectionRange(0, 0);
if (window.testRunner) {
testRunner.dumpAsText();
eventSender.keyDown("rightArrow");
}
if (tf.selectionStart == 1)
log("Test Passed");
else
log("Test Failed. Selection start: " + tf.selectionStart + " Selection end: " + tf.selectionEnd);
}
function log(msg)
{
var res = document.getElementById('res');
res.innerHTML = res.innerHTML + msg + "<br>";
}
</script>
</head>
<body onload="test()">
This tests that you can use arrow keys to navigate.<br>
<input id="tf" value="test"></input>
<div id="res"></div>
</body>
</html>