blob: 4ace48ce256d7ee2337ff3489743fa354b954598 [file] [log] [blame]
<script>
if (window.testRunner)
testRunner.dumpAsText();
function log(s)
{
if (window.testRunner)
alert(s);
else
logger.document.write('<p>' + s + '</p>');
}
function shouldBe(a, b)
{
var evalA;
try {
evalA = eval(a)
} catch (e) {
evalA = 'Caught exception: ' + e;
}
if (evalA == b)
log('PASS: ' + a + ' should be ' + b + ' and is.\n');
else
log('FAIL: ' + a + ' should be ' + b + ' but instead is ' + evalA + '.\n');
}
</script>
<frameset rows="250, *">
<frameset cols="*, 250">
<frame name="logger">
<frame
name="frame"
src="javascript:
top.log('This page tests whether an iframe correctly reports renderer-dependent values ' +
'when executing a javascript: load. If the test passes, you\'ll see a series of ' +
'\'PASS\' messages below.\n'
);
top.shouldBe('frame.frameElement.width', 250);
top.shouldBe('frame.frameElement.clientWidth', 250);
top.shouldBe('frame.frameElement.height', 250);
top.shouldBe('frame.frameElement.clientHeight', 250);
"
>
</frameset>
</frameset>