blob: 976b55d02f3397293449f0c29e36293e90106c1f [file] [log] [blame]
<div id="edit" contentEditable="true">foo<br>bar</div>
<script>
if (window.testRunner)
window.testRunner.dumpAsText();
edit = document.getElementById("edit");
window.getSelection().collapse(edit, 0);
document.execCommand("SelectAll");
document.execCommand("InsertUnorderedList");
document.execCommand("Undo");
text = document.createTextNode("This tests for a crash when undoing and then redoing after some arbitrary DOM operations are performed that effect the Undo stack. The test should not crash.");
edit.innerHTML = "";
edit.appendChild(text);
document.execCommand("Undo");
document.execCommand("Redo");
</script>