[wpt-sync] Sync PR 39932 - [wptrunner] Allow test window reuse for Chrome
Categories
(Testing :: web-platform-tests, task, P4)
Tracking
(firefox116 fixed)
Tracking | Status | |
---|---|---|
firefox116 | --- | fixed |
People
(Reporter: wpt-sync, Unassigned)
References
()
Details
(Whiteboard: [wptsync downstream])
Sync web-platform-tests PR 39932 into mozilla-central (this bug is closed when the sync is complete).
PR: https://github.com/web-platform-tests/wpt/pull/39932
Details from upstream follow.
Jonathan Lee <jonathanjlee@google.com> wrote:
[wptrunner] Allow test window reuse for Chrome
Currently, the base WebDriver testharness executor creates a new window (i.e., tab) for every test. For Chrome controlled via chromedriver, the overhead of creating the window and synchronously polling the remote end until the window's handle loads
about:blank
is substantial (~0.35s per test).This change adds a Chrome-specific wptrunner flag
--reuse-window
to persist and reuse a test window so long as the runner window does not need to be reloaded. To emulate the creation of a new window, the executor navigates toabout:blank
and clears the navigation history via a Chrome DevTools Protocol call, which has a lower per-test overhead of ~0.07s.Empirically, in aggregate, this reduces total shard runtime from 135+ min -> 120-125 min with no systemic increases in flakiness [1, 2].
--reuse-window
is also useful for debugging the renderer process in multiple tests. When a test window is closed, the underlying renderer process is replaced, which breaks the connection to the debugger.The existing behavior is preserved without
--reuse-window
.[1]: With patch: https://ci.chromium.org/ui/p/chromium/builders/try/linux-wpt-fyi-rel/1877/overview
[2]: Without patch: https://ci.chromium.org/ui/p/chromium/builders/ci/linux-wpt-fyi-rel/41852/overview
Assignee | ||
Comment 1•2 years ago
|
||
Assignee | ||
Updated•2 years ago
|
Assignee | ||
Updated•2 years ago
|
Assignee | ||
Comment 2•2 years ago
|
||
Assignee | ||
Comment 3•2 years ago
|
||
Assignee | ||
Comment 5•2 years ago
|
||
Comment 6•2 years ago
|
||
bugherder |
Description
•