blob: 1eb04e9961820fb1a2934d889fb590052d1c9ccf [file] [log] [blame]
<!DOCTYPE html><!-- webkit-test-runner [ experimental:WebAnimationsCSSIntegrationEnabled=false ] -->
<html>
<head>
<script src="../../../resources/js-test-pre.js"></script>
</head>
<body>
<iframe src="../../../fast/animation/script-tests/request-animation-frame-subframe.html" width="700" height="500"></iframe>
<script type="text/javascript" charset="utf-8">
description("Tests requestAnimationFrame in both an iframe and main frame");
var callbackInvoked = false;
var mainFrameCallbackInvoked = false;
if (window.testRunner) {
testRunner.dumpAsText();
testRunner.waitUntilDone();
}
window.requestAnimationFrame(function() {
mainFrameCallbackInvoked = true;
});
// Called from subframe.
function doDisplay()
{
if (window.testRunner)
testRunner.displayAndTrackRepaints();
}
function doCheckResult()
{
shouldBeTrue("callbackInvoked");
shouldBeTrue("mainFrameCallbackInvoked");
}
function doTestDone()
{
isSuccessfullyParsed();
if (window.testRunner)
testRunner.notifyDone();
}
</script>
</body>
</html>