5 B
= document
.getElementById("span-B");
6 B
.customProperty
= "B";
8 document
.getElementById("div").innerHTML
= "<span>replacement content</span>";
10 // create lots of objects to force a garbage collection
18 var output
= document
.getElementById("output");
20 output
.innerHTML
+= B
.customProperty
+ "<BR>";
22 output
.innerHTML
+= "parent node exists<BR>";
25 output
.innerHTML
+= "child node exists<BR>";
29 if (window
.testRunner
) {
30 testRunner
.dumpAsText();
36 <body onload=
"doit()">
37 <div style=
"border: 1px solid red">
39 This test verifies that DOM nodes are retained because a wrapper exists for a descendant. A wrapper need not exist for the node itself or for an ancestor.
42 The output should be the following pieces of text on lines by themselves:
"replacement content",
"B",
"parent node exists",
"child node exists".
46 <span id=
"span-A"><span id=
"span-B"><span id=
"span-C">original span
</span></span></span>