Closed Bug 1808961 Opened 2 years ago Closed 2 years ago

[wpt-sync] Sync PR 37780 - Refactor and remove buffer option

Categories

(Core :: DOM: Performance, task, P4)

task

Tracking

()

RESOLVED FIXED
111 Branch
Tracking Status
firefox111 --- fixed

People

(Reporter: mozilla.org, Unassigned)

References

(Depends on 1 open bug, )

Details

(Whiteboard: [wptsync downstream])

Sync web-platform-tests PR 37780 into mozilla-central (this bug is closed when the sync is complete).

PR: https://github.com/web-platform-tests/wpt/pull/37780
Details from upstream follow.

Hao Liu <haoliuk@chromium.org> wrote:

Refactor and remove buffer option

The test was flaky for 2 reasons.
1, By the time the beforeRender timestamp is taken, the image may
already be rendered. The assertion that renderTime >= beforeRender
therefore could fail.

A previous CL fixes this. But the 2nd flakiness cause is found.

2, There was an assertion in the original test that the entryList of the
performance observer callback should be of size 1. This assertion is
carried over to the fix and is found to be causing flakiness as well.
It is because the performance observer has buffered option. At the
invocation of observer.observe(..}), the observer picks up the previous
entries and fire a deliver of the observer. Then, if this deliver is
actually executed after the 2nd element timing entry is added, the
entryList size would be 2. The assertion then fails.

This CL fix it by removing the buffered option.

Bug: 1394227,1403318
Change-Id: I58a9da6832bccd4377696c7d7f50508ef1254011
Reviewed-on: https://chromium-review.googlesource.com/4139461
WPT-Export-Revision: 161defb68071682b59763d730f6160ed4d8ff45b

Component: web-platform-tests → DOM: Performance
Product: Testing → Core

CI Results

Ran 0 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI

Total 40 tests and 1 subtests

Status Summary

Firefox

OK : 40
FAIL: 40

Chrome

OK : 40
PASS: 40

Safari

OK : 40
FAIL: 40

Links

GitHub PR Head
GitHub PR Base

Details

New Tests That Don't Pass

Pushed by wptsync@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/14761c577405 [wpt PR 37780] - De-flake element-timing/image-src-change.html, a=testonly
Status: NEW → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 111 Branch
You need to log in before you can comment on or make changes to this bug.