003-1.html (1016B)
1 <!DOCTYPE HTML> 2 <script> 3 var t = opener.t; 4 var do_test = t.step_func(function() { 5 localStorage.test6564729 += '1'; 6 var d = document; 7 var e = document.open(); // has no effect (ignore-opens-during-unload > 0 because we're in beforeunload) 8 localStorage.test6564729 += (e == d) ? '2' : 'A [' + e + '] '; 9 document.write('FAIL - document.write executed and blocked navigation!'); // has no effect (ignore-opens-during-unload > 0) 10 localStorage.test6564729 += document.body.textContent.match('FAIL') ? 'B' : '3'; 11 document.close(); // has no effect (no script-created parser) 12 localStorage.test6564729 += '4'; 13 }) 14 15 onload=t.step_func(function() {localStorage.test6564729 = '0'; setTimeout(t.step_func(function() {document.links[0].click()}), 100)}) 16 17 </script> 18 <body 19 onbeforeunload="do_test()" 20 onpagehide="localStorage.test6564729 += '6'" 21 onunload="localStorage.test6564729 += '7'"> 22 <p><a href="003a.html">Follow this link to run the test.</a> 23 <p><iframe src="003b.html"></iframe>