tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

test_xray_event_constructor.xhtml (1148B)


      1 <?xml version="1.0"?>
      2 <?xml-stylesheet type="text/css" href="chrome://global/skin"?>
      3 <?xml-stylesheet type="text/css" href="chrome://mochikit/content/tests/SimpleTest/test.css"?>
      4 <!--
      5 https://bugzilla.mozilla.org/show_bug.cgi?id=861493
      6 -->
      7 <window title="Mozilla Bug 861493"
      8        xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
      9  <script src="chrome://mochikit/content/tests/SimpleTest/SimpleTest.js"/>
     10 
     11  <iframe id="t" type="content"></iframe>
     12  
     13  <!-- test results are displayed in the html:body -->
     14  <body xmlns="http://www.w3.org/1999/xhtml">
     15  <a href="https://bugzilla.mozilla.org/show_bug.cgi?id=861493"
     16     target="_blank">Mozilla Bug 861493</a>
     17  </body>
     18 
     19  <!-- test code goes here -->
     20  <script type="application/javascript">
     21  <![CDATA[
     22  /** Test for Bug 861493 */
     23   SimpleTest.waitForExplicitFinish();
     24 
     25   addLoadEvent(function() {
     26     ok(Cu.isXrayWrapper($("t").contentWindow),
     27        "Should have xray");
     28     var e = new ($("t").contentWindow).Event("test", { bubbles: true });
     29     is(e.bubbles, true, "Dictionary should have worked");
     30     SimpleTest.finish();
     31   })
     32 
     33  ]]>
     34  </script>
     35 </window>