| OLD | NEW |
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 <html> | 2 <html> |
| 3 <script src="../../../resources/js-test.js"></script> | 3 <script src="../../../resources/js-test.js"></script> |
| 4 <head> | 4 <head> |
| 5 <link id="importLink" rel="import" href="resources/hello.html"> | 5 <link id="importLink" rel="import" href="resources/hello.html"> |
| 6 </head> | 6 </head> |
| 7 <body> | 7 <body> |
| 8 <script> | 8 <script> |
| 9 shouldBe("importLink.import.defaultView", "document.defaultView"); | 9 shouldBe("importLink.import.defaultView", "document.defaultView"); |
| 10 | 10 |
| 11 window.jsTestIsAsync = true; |
| 12 |
| 11 var xhr = new XMLHttpRequest(); | 13 var xhr = new XMLHttpRequest(); |
| 12 xhr.open("GET", "resources/root.html", false); | 14 xhr.open("GET", "resources/root.html", true); |
| 13 xhr.responseType = "document"; | 15 xhr.responseType = "document"; |
| 16 xhr.onload = function() { |
| 17 shouldBeNull("xhr.response.defaultView"); |
| 18 |
| 19 createdDoc = document.implementation.createHTMLDocument("Hello"); |
| 20 shouldBeNull("createdDoc.defaultView"); |
| 21 finishJSTest(); |
| 22 }; |
| 14 xhr.send(); | 23 xhr.send(); |
| 15 shouldBeNull("xhr.response.defaultView"); | |
| 16 | |
| 17 createdDoc = document.implementation.createHTMLDocument("Hello"); | |
| 18 shouldBeNull("createdDoc.defaultView"); | |
| 19 | 24 |
| 20 </script> | 25 </script> |
| 21 </body> | 26 </body> |
| 22 </html> | 27 </html> |
| OLD | NEW |