4 testRunner
.dumpAsText();
7 XPathResult
.ORDERED_NODE_ITERATOR_TYPE
,
8 XPathResult
.UNORDERED_NODE_ITERATOR_TYPE
13 if (window
.GCController
)
14 return GCController
.collect();
16 for (var i
= 0; i
< 10000; i
++) { // > force garbage collection (FF requires about 9K allocations before a collect)
17 var s
= new String("abc");
23 var doc
= (new DOMParser
).parseFromString("<html><body><span></span></body></html>", "text/xml");
24 doc
.getElementsByTagName("span")[0].foo
= "PASS";
25 var result
= doc
.evaluate("//span", doc
.documentElement
, null, type
, null);
28 var console
= document
.getElementById("console");
29 console
.appendChild(document
.createTextNode(result
.iterateNext().foo
));
30 console
.appendChild(document
.createElement("br"));
35 while (types
.length
) {
41 <body onload=
"tests()">
42 <div> Test for bug
<a href=
"https://bugs.webkit.org/show_bug.cgi?id=34231">34231</a>: Nodes in XPathResult should keep JS wrappers alive.
</div>
43 <div> For this test to PASS you should see
2 PASS below.
</div><br>
44 <div id=
"console"></div>