| OLD | NEW | 
|---|
| (Empty) |  | 
|  | 1 <!DOCTYPE html> | 
|  | 2 <p>Test of createContextualFragment from a Range whose context is an HTML docume
    nt without a body. If the test succeeds you will see the word "PASS" below.</p> | 
|  | 3 <p id="result"></p> | 
|  | 4 <script> | 
|  | 5 if (window.testRunner) | 
|  | 6     testRunner.dumpAsText(); | 
|  | 7 | 
|  | 8 var doc = document.implementation.createHTMLDocument(); | 
|  | 9 var div = doc.createElement('div'); | 
|  | 10 doc.replaceChild(div, doc.documentElement); | 
|  | 11 | 
|  | 12 var range = doc.createRange(); | 
|  | 13 var fragment = range.createContextualFragment('<p id="fragment">Inserted fragmen
    t</p>'); | 
|  | 14 div.appendChild(fragment); | 
|  | 15 var p = doc.getElementById('fragment'); | 
|  | 16 | 
|  | 17 var result = document.getElementById('result'); | 
|  | 18 result.textContent = (p && p.parentElement === div && p.namespaceURI === 'http:/
    /www.w3.org/1999/xhtml') ? 'PASS' : 'FAIL'; | 
|  | 19 </script> | 
|  | 20 | 
| OLD | NEW | 
|---|