| OLD | NEW |
| (Empty) | |
| 1 <body> |
| 2 <div style="height: 2000px;"></div> |
| 3 <script> |
| 4 if (window.testRunner) { |
| 5 testRunner.dumpAsText(); |
| 6 testRunner.waitUntilDone(); |
| 7 } |
| 8 |
| 9 function test() { |
| 10 if (sessionStorage.getItem('replaceState-beforeunload') == 'true') { |
| 11 sessionStorage.removeItem("replaceState-beforeunload"); |
| 12 document.body.appendChild(document.createTextNode( |
| 13 "Scroll state should not be propagated between unrelated documents:
" + |
| 14 (window.scrollY == 0 ? "PASS" : "FAIL"))); |
| 15 if (window.testRunner) |
| 16 testRunner.notifyDone(); |
| 17 } else { |
| 18 sessionStorage.setItem('replaceState-beforeunload', 'true'); |
| 19 location = "resources/replaceState-during-beforeunload.html"; |
| 20 } |
| 21 } |
| 22 |
| 23 window.onload = function() { |
| 24 setTimeout(test, 0); |
| 25 }; |
| 26 </script> |
| 27 </body> |
| OLD | NEW |