Chromium Code Reviews| Index: LayoutTests/svg/as-image/animated-svg-as-image-no-fixed-intrinsic-size.html |
| diff --git a/LayoutTests/svg/as-image/animated-svg-as-image-no-fixed-intrinsic-size.html b/LayoutTests/svg/as-image/animated-svg-as-image-no-fixed-intrinsic-size.html |
| index e1e7371070cc7b4d15d1fd6a0d7eaeb527bd2823..af5e8a1a9f3930d62db11f2821f346d251a500f7 100644 |
| --- a/LayoutTests/svg/as-image/animated-svg-as-image-no-fixed-intrinsic-size.html |
| +++ b/LayoutTests/svg/as-image/animated-svg-as-image-no-fixed-intrinsic-size.html |
| @@ -10,10 +10,13 @@ |
| if (!window.testRunner) |
| return; |
| - // The animation lasts 100ms. Wait 200ms for the repaint. |
| - setTimeout(function() { |
| + // The animation lasts 100ms so skip 12 frames to be sure. |
|
fs
2015/09/08 14:50:56
Ditto.
|
| + for (var i = 0; i < 12; i++) |
| + window.internals.advanceImageAnimation(image); |
| + |
| + window.requestAnimationFrame(function() { |
| finishRepaintTest(); |
| - }, 200); |
| + }); |
| } |
| </script> |
| <style type="text/css" media="screen"> |
| @@ -24,6 +27,6 @@ |
| </head> |
| <body onload="runRepaintAndPixelTest()"> |
| <p>Images should redraw correctly when SVG animation runs</p> |
| - <img src="resources/animated-rect-fixed-size.svg"> |
| + <img id="image" src="resources/animated-rect-fixed-size.svg"> |
| </body> |
| </html> |