| <html xmlns="http://www.w3.org/1999/xhtml"> |
| testRunner.waitUntilDone(); |
| var div = document.getElementsByTagName('div')[0]; |
| div.parentNode.removeChild(div); |
| var n = document.createElement("p"); |
| n.appendChild(document.createTextNode(text)); |
| document.body.appendChild(n); |
| msg("Test for bug 30049: Manipulating DOM from a script while parsing XHTML can cause a crash."); |
| // Even though a subtree is removed, parsing continues. |
| msg(div.getElementsByTagName("foo").length == 1 ? "PASS" : "FAIL"); |
| alert("FAIL"); // Firefox compatibility. |