blob: d62e890fd22020dfd1834218934d27d4bc16398d [file] [log] [blame]
<div contenteditable>
0123456789
</div>
<script>
if (window.testRunner)
testRunner.dumpAsText();
onload = function() {
var textarea = document.getElementById("textarea");
textarea.focus();
var hasBeenBlurred = false;
textarea.onblur = function() {
hasBeenBlurred = true;
}
document.execCommand("InsertText", false, "te");
document.execCommand("InsertText", false, "h");
document.execCommand("InsertText", false, " ");
document.execCommand("InsertText", false, "test result is");
var result = textarea.value === "the test result is" ? "PASS" : "FAIL";
document.getElementById("result").appendChild(document.createTextNode(result));
}
</script>
<textarea id="textarea"></textarea>
<p id="result"></p>