<p>This tests for a hang when turning a selection that starts before a table and ends inside that table into a list. You should see one list item with the table.  <b>There is a bug that causes an extra empty list item to be created after the table.</b></p>
<div id="div" contenteditable="true"><table border="1" width="100px"><tr><td>foo<br><br><br><span id="span">bar</span></td></tr></table><br></div>

<script>
if (window.testRunner)
    window.testRunner.dumpAsText();
div = document.getElementById("div");
span = document.getElementById("span");

sel = window.getSelection();
sel.setBaseAndExtent(div, 0, span, span.childNodes.length);
document.execCommand("InsertOrderedList");
</script>
