Make test cases for bug 490182 not assume that <table> is the parent of <col>

This commit is contained in:
Henri Sivonen 2009-06-12 14:55:44 +03:00
parent fd88f74e47
commit 7e5cad2e1d
2 changed files with 4 additions and 5 deletions

View File

@ -4,13 +4,13 @@
<script type="text/javascript">
function boom()
{
var table = document.getElementById("table");
var col1 = document.getElementById("col1");
var parent = col1.parentNode;
var next = col1.nextSibling;
table.removeChild(col1);
parent.removeChild(col1);
reflow();
table.insertBefore(col1, next);
parent.insertBefore(col1, next);
reflow();
col1.removeAttribute("width");
}

View File

@ -4,12 +4,11 @@
<script type="text/javascript">
function boom()
{
var table = document.getElementById("table");
var col1 = document.createElement("col");
col1.setAttribute("width", "100");
var next = document.getElementById("col2");
table.insertBefore(col1, next);
next.parentNode.insertBefore(col1, next);
reflow();
col1.removeAttribute("width");
}