window.name leaks information across domains
[WebKit-https.git] / LayoutTests / fast / events / script-tests / onunload-back-to-page-cache.js
1 description('Simulates flow from a page that\'s in the page cache to one that\'s not, and then back to the page cached page.');
2
3 onpageshow = function(event) {
4     if (window.history.state == 'navigated') {
5         testPassed('WebTiming asserts in FrameLoader.cpp did not fire');
6         finishJSTest();
7     } else {
8         if (window.testRunner)
9             testRunner.overridePreference('WebKitUsesPageCachePreferenceKey', 1);
10         setTimeout(function() {window.history.replaceState('navigated', ''); location.href = 'data:text/html,<script>onunload=function() {},onload=function(){history.back();}<' + '/script>';}, 0);
11     }
12 }
13
14 var jsTestIsAsync = true;