docshell/test/navigation/test_sessionhistory.html

Wed, 31 Dec 2014 06:09:35 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Wed, 31 Dec 2014 06:09:35 +0100
changeset 0
6474c204b198
permissions
-rw-r--r--

Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.

     1 <!DOCTYPE HTML>
     2 <html>
     3 <!--
     4 https://bugzilla.mozilla.org/show_bug.cgi?id=
     5 -->
     6 <head>
     7   <title>Test for Bug </title>
     8   <script type="application/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
     9   <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css"/>
    10 </head>
    11 <body onload="nextTest()">
    12 <a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=">Mozilla Bug </a>
    13 <p id="display"></p>
    14 <div id="content" style="display: none">
    16 </div>
    17 <pre id="test">
    18 <script type="application/javascript">
    20 /** Test for Bug  **/
    22 var testFiles =
    23   [ "file_bug462076_1.html",         // Dynamic frames before onload
    24     "file_bug462076_2.html",         // Dynamic frames when handling onload
    25     "file_bug462076_3.html",         // Dynamic frames after onload
    26     "file_bug508537_1.html",         // Dynamic frames and forward-back
    27     "file_document_write_1.html",    // Session history + document.write
    28     "file_static_and_dynamic_1.html",// Static and dynamic frames and forward-back
    29     "file_bug534178.html",           // Session history transaction clean-up.
    30     "file_fragment_handling_during_load.html"
    31   ];
    32 var testCount = 0; // Used by the test files.
    34 SimpleTest.waitForExplicitFinish();
    36 var testWindow;
    37 function nextTest_() {
    38   if (testFiles.length) {
    39     testCount = 0;
    40     testWindow = window.open(testFiles.shift(), "", "width=300,height=300");
    41     testWindow.onunload = function () { } //XXX
    42   } else {
    43     SimpleTest.finish();
    44   }
    45 }
    47 // Needed by file_document_write_1.html
    48 function isTestDynamic() {
    49   var dyn = testWindow.document.getElementById("dynamic");
    50   is(dyn, null, "Should have gone back to the static page!");
    51   nextTest();
    52   testWindow.close();
    53 }
    55 function nextTest() {
    56   setTimeout(nextTest_, 0);
    57 }
    59 </script>
    60 </pre>
    61 </body>
    62 </html>

mercurial