Bug 1776680 [wpt PR 34603] - [@container] Test invalidation of font-relative units...
[gecko.git] / dom / events / test / test_bug412567.html
blob86f7001fc21d80b336b58b8575ca0c1a80add057
1 <!DOCTYPE HTML>
2 <html>
3 <!--
4 https://bugzilla.mozilla.org/show_bug.cgi?id=412567
5 -->
6 <head>
7 <title>Test for Bug 412567</title>
8 <script src="/tests/SimpleTest/SimpleTest.js"></script>
9 <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
10 </head>
11 <body onload="testRedispatching(event);">
12 <a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=412567">Mozilla Bug 412567</a>
13 <p id="display"></p>
14 <div id="content" style="display: none" onload="redispatchinHandler(event)">
16 </div>
17 <pre id="test">
18 <script class="testbody" type="text/javascript">
20 /** Test for Bug 412567 **/
22 var loadEvent = null;
24 function redispatchinHandler(evt) {
25 is(evt.type, "load", "Wrong event type!");
26 ok(!evt.isTrusted, "Event should not be trusted!");
27 SimpleTest.finish();
30 function redispatch() {
31 ok(loadEvent.isTrusted, "Event should be trusted before redispatching!");
32 document.getElementById('content').dispatchEvent(loadEvent);
35 function testRedispatching(evt) {
36 is(evt.type, "load", "Wrong event type!");
37 ok(evt.isTrusted, "Event should be trusted!");
38 loadEvent = evt;
39 setTimeout(redispatch, 0);
42 SimpleTest.waitForExplicitFinish();
43 </script>
44 </pre>
45 </body>
46 </html>