<!DOCTYPE html>
<html>
<head>
<script src="../../resources/js-test.js"></script>
</head>
<body>
<script>
description("Tests basic use of requestAnimationFrame");
jsTestIsAsync = true;

if (window.testRunner)
    testRunner.displayAndTrackRepaints();

let callbackCount = 0;
let rAFCallback = () => {
    testPassed("requestAnimationFrame callback was called");
    callbackCount++;
    if (callbackCount < 5)
        requestAnimationFrame(rAFCallback);
    else
       finishJSTest();
}

requestAnimationFrame(rAFCallback);

</script>
</body>
</html>
