| OLD | NEW |
| (Empty) |
| 1 | |
| 2 <script src="../../resources/js-test.js"></script> | |
| 3 </head> | |
| 4 <script> | |
| 5 function runTest() { | |
| 6 plugin = document.getElementById('plugin'); | |
| 7 | |
| 8 // Get our test object. | |
| 9 testObject = plugin.testObject; | |
| 10 | |
| 11 // Now destroy the plugin. | |
| 12 plugin.parentNode.removeChild(plugin); | |
| 13 | |
| 14 // testObject is now a dangling object and every operation on it should thro
w. | |
| 15 shouldThrow('testObject.gettingProperty'); | |
| 16 shouldThrow('testObject.settingProperty = 10'); | |
| 17 shouldThrow('testObject()'); | |
| 18 shouldThrow('new testObject();') | |
| 19 } | |
| 20 </script> | |
| 21 <body onLoad="runTest()"> | |
| 22 <embed id="plugin" type="application/x-webkit-test-netscape" test="npruntime-obj
ect-from-destroyed-plugin"></embed> | |
| 23 <p id="description"></p> | |
| 24 <div id="console"></div> | |
| 25 | |
| 26 <script> | |
| 27 description("Test various operation on an NPObject whose plugin has been destroy
ed"); | |
| 28 | |
| 29 </script> | |
| OLD | NEW |