| Index: third_party/WebKit/LayoutTests/fast/table/resources/wait-for-onload.js
|
| diff --git a/third_party/WebKit/LayoutTests/fast/table/resources/wait-for-onload.js b/third_party/WebKit/LayoutTests/fast/table/resources/wait-for-onload.js
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..4afdabc11c106987c99dcf02814bf47929a8d0e6
|
| --- /dev/null
|
| +++ b/third_party/WebKit/LayoutTests/fast/table/resources/wait-for-onload.js
|
| @@ -0,0 +1,15 @@
|
| +if (window.testRunner) {
|
| + // This is a workaroud for an issue that the test runner sends notifyDone
|
| + // before resources specified in CSS url finish loading. Currently all
|
| + // such resources are specified in inline CSSs so we can rely on the
|
| + // Document load event (Note that we cannot rely on that with linked
|
| + // CSSs).
|
| + testRunner.waitUntilDone();
|
| + window.addEventListener('load', () => {
|
| + // Force layout.
|
| + document.body.offsetTop;
|
| +
|
| + testRunner.notifyDone();
|
| + });
|
| +}
|
| +
|
|
|