|
1 <!DOCTYPE HTML> |
|
2 <html> |
|
3 <!-- |
|
4 https://bugzilla.mozilla.org/show_bug.cgi?id=553982 |
|
5 --> |
|
6 <head> |
|
7 <title>Test for Bug 553982</title> |
|
8 <script type="application/javascript" src="/MochiKit/MochiKit.js"></script> |
|
9 <script type="application/javascript" src="/tests/SimpleTest/SimpleTest.js"></script> |
|
10 <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css"/> |
|
11 </head> |
|
12 <body> |
|
13 <a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=553982">Mozilla Bug 553982</a> |
|
14 <pre id="test"> |
|
15 <script type="application/javascript"> |
|
16 |
|
17 SimpleTest.waitForExplicitFinish(); |
|
18 var success = false; |
|
19 |
|
20 // This should fire |
|
21 function doError() { |
|
22 success = true; |
|
23 } |
|
24 |
|
25 // This should not fire |
|
26 function doLoad() { |
|
27 ok(false, "onload should not fire"); |
|
28 } |
|
29 |
|
30 window.onload = function() { |
|
31 ok(success, "onerror should fire"); |
|
32 SimpleTest.finish(); |
|
33 } |
|
34 |
|
35 </script> |
|
36 </pre> |
|
37 <img src="data:text/html," onerror="doError()" onload="doLoad()" /> |
|
38 </body> |
|
39 </html> |