| Index: third_party/WebKit/LayoutTests/compositing/overflow/overflow-positioning.html
|
| diff --git a/third_party/WebKit/LayoutTests/compositing/overflow/overflow-positioning.html b/third_party/WebKit/LayoutTests/compositing/overflow/overflow-positioning.html
|
| index d0a1874386f5de743151d78a57cf4e94fc6ef88f..1af9aa7e4a90b0489c1ec390af80372f745e3ac0 100644
|
| --- a/third_party/WebKit/LayoutTests/compositing/overflow/overflow-positioning.html
|
| +++ b/third_party/WebKit/LayoutTests/compositing/overflow/overflow-positioning.html
|
| @@ -54,18 +54,23 @@
|
| if (window.testRunner)
|
| testRunner.waitUntilDone();
|
|
|
| + function waitForCompositor() {
|
| + return document.body.animate({opacity: [1, 1]}, 1).finished;
|
| + }
|
| +
|
| function startTest()
|
| {
|
| - window.setTimeout(function() {
|
| - var mover = document.getElementById('mover');
|
| - mover.className = 'moving';
|
| -
|
| - window.setTimeout(function() {
|
| - if (window.testRunner)
|
| - testRunner.notifyDone();
|
| - }, 0);
|
| -
|
| - }, 0);
|
| + var mover = document.getElementById('mover');
|
| + getComputedStyle(mover).transform; // Force style recalc
|
| + mover.className = 'moving';
|
| + if (window.internals)
|
| + internals.pauseAnimations(0);
|
| +
|
| + waitForCompositor().then(() => {
|
| + if (window.testRunner) {
|
| + testRunner.notifyDone();
|
| + }
|
| + });
|
| }
|
|
|
| window.addEventListener('load', startTest, false);
|
|
|