Reverting r42321 because it broke some layout tests.
[WebKit-https.git] / LayoutTests / plugins / netscape-throw-exception.html
1 <html>
2 <script>
3 function runTest()
4 {
5     if (window.layoutTestController)
6         layoutTestController.dumpAsText();
7
8     var plugin = document.getElementById("testPlugin");
9     var result1 = document.getElementById('result1');
10     try {
11         plugin.testThrowException();
12     } catch (e) {
13         result1.innerHTML = e.message;
14     }
15     var result2 = document.getElementById('result2');
16     try {
17         plugin.testObject.throwException();
18     } catch (e) {
19         result2.innerHTML = e.message;
20     }
21 }
22 </script>
23
24 <body onload="runTest();">
25 <embed id="testPlugin" type="application/x-webkit-test-netscape" width="200" height="200"></embed>
26 This tests that a plugin can throw exceptions. If this test is successful the text "SUCCESS" twice below.
27 <div id="result1">FAILURE</div>
28 <div id="result2">FAILURE</div>
29 </body>
30 </html>