|
1 <html xmlns="http://www.w3.org/1999/xhtml"> |
|
2 <head> |
|
3 <title>slave for sessionStorage test</title> |
|
4 |
|
5 <script type="text/javascript" src="interOriginSlave.js"></script> |
|
6 <script type="text/javascript"> |
|
7 |
|
8 var currentStep = 2; |
|
9 |
|
10 function doStep() |
|
11 { |
|
12 switch (currentStep) |
|
13 { |
|
14 case 2: |
|
15 is(sessionStorage.length, 0, "Num of items is 0"); |
|
16 |
|
17 sessionStorage.setItem("C", "3"); |
|
18 is(sessionStorage.getItem("C"), "3", "C is 3 in the slave"); |
|
19 is(sessionStorage.length, 1, "Num of items is 1"); |
|
20 break; |
|
21 |
|
22 case 4: |
|
23 is(sessionStorage.getItem("C"), "3", "C is 3 in the slave"); |
|
24 is(sessionStorage.length, 1, "Num of items is 1"); |
|
25 break; |
|
26 |
|
27 case 6: |
|
28 return finishTest(); |
|
29 } |
|
30 |
|
31 ++currentStep; |
|
32 ++currentStep; |
|
33 |
|
34 return true; |
|
35 } |
|
36 |
|
37 </script> |
|
38 |
|
39 </head> |
|
40 |
|
41 <body onload="postMsg('frame loaded');"> |
|
42 </body> |
|
43 </html> |