Chromium Code Reviews| Index: third_party/WebKit/LayoutTests/inspector/tracing/timeline-layout/timeline-layout-with-invalidations.html |
| diff --git a/third_party/WebKit/LayoutTests/inspector/tracing/timeline-layout/timeline-layout-with-invalidations.html b/third_party/WebKit/LayoutTests/inspector/tracing/timeline-layout/timeline-layout-with-invalidations.html |
| index 0c16a28f414eeeb64e8e583bff431dd31a0c31f4..691f345da1812db3556803ac07b6b217569f9e87 100644 |
| --- a/third_party/WebKit/LayoutTests/inspector/tracing/timeline-layout/timeline-layout-with-invalidations.html |
| +++ b/third_party/WebKit/LayoutTests/inspector/tracing/timeline-layout/timeline-layout-with-invalidations.html |
| @@ -4,8 +4,10 @@ |
| <script src="../../../http/tests/inspector/inspector-test.js"></script> |
| <script src="../../../http/tests/inspector/timeline-test.js"></script> |
| <script> |
| -function display(callback) |
| +function display() |
| { |
| + var callback; |
| + var promise = new Promise((fulfill) => callback = fulfill); |
| requestAnimationFrame(function() { |
|
caseq
2016/08/10 22:44:55
do we still need these actions to be done under rA
kozy
2016/08/11 01:34:16
Done.
|
| document.getElementById("testElement").style.width = "100px"; |
| var forceLayout1 = document.body.offsetTop; |
| @@ -14,10 +16,13 @@ function display(callback) |
| if (window.testRunner) |
| testRunner.layoutAndPaintAsyncThen(callback); |
| }); |
| + return promise; |
| } |
| -function updateSubframeAndDisplay(callback) |
| +function updateSubframeAndDisplay() |
| { |
| + var callback; |
| + var promise = new Promise((fulfill) => callback = fulfill); |
| requestAnimationFrame(function() { |
| frames[0].document.body.children[0].style.width = "10px"; |
| var forceLayout1 = frames[0].document.body.offsetTop; |
| @@ -26,6 +31,7 @@ function updateSubframeAndDisplay(callback) |
| if (window.testRunner) |
| testRunner.layoutAndPaintAsyncThen(callback); |
| }); |
| + return promise; |
| } |
| function test() |