3 <script src=
"../../resources/js-test.js"></script>
4 <meta http-equiv=
"pragma" content=
"no-cache">
5 <meta http-equiv=
"cache-control" content=
"no-cache">
7 <body onload=
"startTest()">
8 <input name=
"name1" id=
"input1">
9 <iframe id=
"frame1" src=
"resources/form-state-restore-with-frames-1.html">
11 <form id=
"form1" action=
"data:text/html,<script>history.back();</script>">
17 return document
.getElementById(id
);
19 function frame
$(frame
, id
) {
20 return frame
.contentDocument
.getElementById(id
);
23 function startTest() {
24 if ($('input1').value
== 'visited') {
25 shouldBeEqualToString('frame$($("frame1"), "input2").value', 'value2');
26 shouldBeEqualToString('frame$(frame$($("frame1"), "frame2"), "input3").value', 'value3');
29 setTimeout(function() {
30 $('input1').value
= 'visited';
31 frame
$($('frame1'), 'input2').value
= 'value2';
32 frame
$(frame
$($('frame1'), 'frame2'), 'input3').value
= 'value3';