OLD | NEW |
(Empty) | |
| 1 <!DOCTYPE html> |
| 2 <html> |
| 3 <head> |
| 4 <script src="../../resources/js-test.js"></script> |
| 5 </head> |
| 6 <body> |
| 7 <script> |
| 8 description("Tests that Document.createEvent() throws for SVG Documents when giv
en no argument."); |
| 9 |
| 10 var svgDoc = document.implementation.createDocument("http://www.w3.org/2000/svg"
, "svg", null); |
| 11 shouldBe("svgDoc.__proto__", "XMLDocument.prototype"); |
| 12 shouldBe("svgDoc.__proto__.__proto__", "Document.prototype"); |
| 13 shouldThrow("svgDoc.createEvent()", '"TypeError: Failed to execute \'createEvent
\' on \'Document\': 1 argument required, but only 0 present."'); |
| 14 shouldNotThrow("svgDoc.createEvent('MouseEvents')"); |
| 15 </script> |
| 16 </body> |
| 17 </html> |
OLD | NEW |