| Index: third_party/WebKit/LayoutTests/inspector-protocol/animation/animation-seek-past-end.html
|
| diff --git a/third_party/WebKit/LayoutTests/inspector-protocol/animation/animation-seek-past-end.html b/third_party/WebKit/LayoutTests/inspector-protocol/animation/animation-seek-past-end.html
|
| index d545d124b17859bbc5b36a6d5e51e32b974b67cf..8daecb1fee07062e7caa6c350a3bc70e21c43cc0 100644
|
| --- a/third_party/WebKit/LayoutTests/inspector-protocol/animation/animation-seek-past-end.html
|
| +++ b/third_party/WebKit/LayoutTests/inspector-protocol/animation/animation-seek-past-end.html
|
| @@ -9,13 +9,11 @@ function startAnimation()
|
|
|
| function rafWidth(resolve, reject)
|
| {
|
| - function frameCallback()
|
| - {
|
| - resolve(node.offsetWidth);
|
| - }
|
| -
|
| + var callback;
|
| + var promise = new Promise((fulfill) => callback = fulfill);
|
| if (window.testRunner)
|
| - testRunner.layoutAndPaintAsyncThen(frameCallback);
|
| + testRunner.layoutAndPaintAsyncThen(() => callback(node.offsetWidth));
|
| + return promise;
|
| }
|
|
|
| function test()
|
| @@ -37,10 +35,11 @@ function test()
|
|
|
| function logWidth()
|
| {
|
| - InspectorTest.invokePageFunctionPromise("rafWidth", []).then(function(result) {
|
| - InspectorTest.log(result);
|
| - InspectorTest.completeTest();
|
| - });
|
| + InspectorTest.evaluateInPageAsync("rafWidth()")
|
| + .then(function(result) {
|
| + InspectorTest.log(result);
|
| + InspectorTest.completeTest();
|
| + });
|
| }
|
| }
|
|
|
|
|