Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / storage / domstorage / sessionstorage / window-open.html
blobcc9fae9d34332bc975f3ab93bb7f3c068a0b9db0
1 <html>
2 <head>
3 <script src="resources/clearSessionStorage.js"></script>
4 <script>
6 if (window.testRunner) {
7 testRunner.dumpAsText();
8 testRunner.setCanOpenWindows();
9 testRunner.waitUntilDone();
12 function log(a)
14 document.getElementById("logger").innerHTML += a + "<br>";
17 function runTest()
19 if (!window.sessionStorage) {
20 log("window.sessionStorage DOES NOT exist");
21 return;
24 window.log = log;
26 window.sessionStorage.setItem("FOO", "BAR");
27 log("Value for FOO is " + window.sessionStorage.getItem("FOO"));
28 window.open("resources/window-open-second.html");
33 </script>
34 </head>
35 <body onload="runTest();">
36 This is a new window to make sure there is a copy of the previous window's sessionStorage, and that they diverge after a change<br>
37 <div id="logger"></div>
38 </body>
39 </html>