Closed Bug 1785984 Opened 2 years ago Closed 2 years ago

[wpt-sync] Sync PR 35529 - Minor improvements to remote context helper

Categories

(Core :: DOM: Core & HTML, task, P4)

task

Tracking

()

RESOLVED FIXED
106 Branch
Tracking Status
firefox106 --- fixed

People

(Reporter: wpt-sync, Unassigned)

References

(Depends on 1 open bug, )

Details

(Whiteboard: [wptsync downstream])

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

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

Domenic Denicola <domenic@chromium.org> wrote:

Minor improvements to remote context helper

These make it possible to test prerendering using the helper.

  • Add a url property RemoteContextWrapper. This allows a test to get the resulting URL of a prerendered RemoteContext, so we can later navigate to it.

  • Allow the executorCreator option to createContext() to be async, by awaiting it. This allows it to consist of running script in another RemoteContextWrapper, e.g. to insert \<script type=speculationrules>. (If it is sync, there is no change in behavior; it just waits an extra microtask.)

  • Add a navigateToURL() method to RemoteContextWrapper, to make the simplest cases in which you would use navigate() easier.

  • Clean up a variety of confusing options passing and defaulting code and documentation. There was an overuse of null (instead of the JavaScript-idiomatic default of undefined) which caused optional argument forwarding to need to be manual. As part of this, also fixed up the documentation to denote optional arguments using the appropriate syntax, and to document options as object properties instead of documenting them as if they were arguments.

Change-Id: I3d001f5921aa643e3c1d66d8e4e40b264c6636cc
Reviewed-on: https://chromium-review.googlesource.com/3841185
WPT-Export-Revision: 7f1029de486df1bd59f9192717d872fffe369a38

Component: web-platform-tests → DOM: Core & HTML
Product: Testing → Core

CI Results

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

Total 21 tests

Status Summary

Firefox

ERROR: 18[Gecko-android-em-7.0-x86_64-lite-qr-opt-geckoview, Gecko-android-em-7.0-x86_64-qr-debug-geckoview, Gecko-android-em-7.0-x86_64-qr-opt-geckoview, Gecko-linux1804-64-qr-debug, Gecko-linux1804-64-qr-opt, Gecko-windows10-32-2004-qr-debug, Gecko-windows10-32-2004-qr-opt, Gecko-windows10-64-2004-qr-debug, Gecko-windows10-64-2004-qr-opt] 21[GitHub]

Chrome

ERROR: 21

Safari

ERROR: 21

Links

Gecko CI (Treeherder)
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/4549197994a0 [wpt PR 35529] - Minor improvements to RemoteContext helper, a=testonly https://hg.mozilla.org/integration/autoland/rev/d1bb6ab73f7f [wpt PR 35529] - Update wpt metadata, a=testonly
Status: NEW → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 106 Branch
You need to log in before you can comment on or make changes to this bug.