3 <script src=
"../../../resources/js-test.js"></script>
6 <div id=
"description"></div>
7 <div id=
"console"></div>
9 description('Test constructors for classes in Window');
10 if (window
.testRunner
) {
11 testRunner
.dumpAsText();
14 shouldBe("Audio.prototype.toString.call(new Audio)", "'[object HTMLAudioElement]'");
15 shouldBe("Image.prototype.toString.call(new Image)", "'[object HTMLImageElement]'");
16 shouldBe("Option.prototype.toString.call(new Option)", "'[object HTMLOptionElement]'");
17 shouldBe("WebKitCSSMatrix.prototype.toString.call(new WebKitCSSMatrix)", "'matrix(1.000000, 0.000000, 0.000000, 1.000000, 0.000000, 0.000000)'");
18 shouldBe("WebKitCSSMatrix.prototype.toString.call(new WebKitCSSMatrix())", "'matrix(1.000000, 0.000000, 0.000000, 1.000000, 0.000000, 0.000000)'");
19 shouldThrow("new WebKitCSSMatrix(null)");
20 shouldThrow("new WebKitCSSMatrix(undefined)");
21 shouldBe("XMLHttpRequest.prototype.toString.call(new XMLHttpRequest)", "'[object XMLHttpRequest]'");
22 shouldBe("XSLTProcessor.prototype.toString.call(new XSLTProcessor)", "'[object XSLTProcessor]'");