tor-browser

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

test_performance_navigation.html (1208B)


      1 <!DOCTYPE HTML>
      2 <html>
      3 <!--
      4 https://bugzilla.mozilla.org/show_bug.cgi?id=145971
      5 -->
      6 <head>
      7  <title>Test for Bug 145971</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="runTest()">
     12 <a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=145971">Mozilla Bug 145971</a>
     13 <p id="display"></p>
     14 <div id="content" style="display: none">
     15  
     16 </div>
     17 <pre id="test">
     18 <script type="application/javascript">
     19 var testWindow;
     20 var bc = SpecialPowers.wrap(BroadcastChannel).unpartitionedTestingChannel("bug145971");
     21 bc.onmessage = function(msgEvent) {
     22  var result = msgEvent.data.result;
     23  if (result == undefined) {
     24    info("Got unexpected message from BroadcastChannel");
     25    return;
     26  }
     27  ok(result, "Bug 145971: Navigation type does not equal 2 when restoring document from session history.");
     28  SimpleTest.finish();
     29 };
     30 
     31 function runTest() {
     32  // If Fission is disabled, the pref is no-op.
     33  SpecialPowers.pushPrefEnv({set: [["fission.bfcacheInParent", true]]}, () => {
     34    window.open("test_bug145971.html", "", "width=360,height=480,noopener");
     35  });
     36 }
     37 
     38 </script>
     39 </pre>
     40 </body>
     41 </html>