| <script src="../../resources/js-test-pre.js"></script> |
| description('This page tests invoking as functions JavaScript objects that are provided by plugins.') |
| pluginWithInvokeDefault = document.getElementById('plugin-with-invoke-default'); |
| shouldBe("typeof(pluginWithInvokeDefault)", "'function'"); |
| shouldBe("pluginWithInvokeDefault()", "1") |
| pluginWithoutInvokeDefault = document.getElementById('plugin-without-invoke-default'); |
| shouldBe("typeof(pluginWithoutInvokeDefault)", "'object'"); |
| shouldThrow("pluginWithoutInvokeDefault()"); |
| <body onload="doTest();"> |
| <embed id="plugin-with-invoke-default" type="application/x-webkit-test-netscape" test="plugin-scriptable-npobject-invoke-default"></embed> |
| <embed id="plugin-without-invoke-default" type="application/x-webkit-test-netscape" test="plugin-scriptable-npobject-no-invoke-default"></embed> |