[wpt-sync] Sync PR 63512 - [COOP] Fix top navigation and expectation in navigate-top-to-aboutblank
Categories
(Core :: DOM: Core & HTML, task, P4)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox160 | --- | fixed |
People
(Reporter: wpt-sync, Unassigned)
References
()
Details
(Whiteboard: [wptsync downstream])
Sync web-platform-tests PR 63512 into mozilla-central (this bug is closed when the sync is complete).
PR: https://github.com/web-platform-tests/wpt/pull/63512
Details from upstream follow.
Mike Taylor <miketaylr@chromium.org> wrote:
[COOP] Fix top navigation and expectation in navigate-top-to-aboutblank
navigate-top-to-aboutblank.https.html has been marked [ Failure ] since
CL 2565243 switched the iframe top-navigation from sandbox to
test_driver.bless(). Because the iframe is inside a COOP popup window
with no opener reference to the main testharness window, calling
test_driver.bless() inside the iframe fails in both wptrunner ('Tried to
run in a non-testharness window without a call to set_test_context') and
content_shell, preventing the navigation to about:blank from ever
occurring.Fix this by setting sandbox="allow-top-navigation allow-scripts
allow-same-origin" on the iframe so it can navigate top without a user
gesture while preserving its origin. Also update the third subtest
(opener with COOP: same-origin-allow-popups navigated to about:blank by
a cross-origin iframe) to expect expect_opener_closed = true, as
same-origin-allow-popups only relaxes browsing context group switches
when navigating from an initial empty document, not when navigating the
top-level document itself to COOP: unsafe-none.Remove the [ Failure ] expectation from TestExpectations.
Bug: 40734373
Change-Id: Ie938eaa3fc741e0ba24eb3b22cbe44772f26eca4
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/8549095
Reviewed-by: Ari Chivukula \<arichiv@chromium.org>
Commit-Queue: Ari Chivukula \<arichiv@chromium.org>
Auto-Submit: Mike Taylor \<miketaylr@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1715959}
| Assignee | ||
Updated•1 month ago
|
| Assignee | ||
Comment 1•1 month ago
|
||
Pushed to try (stability) https://treeherder.mozilla.org/jobs?repo=try&landoInstance=lando-prod-2025&landoCommitID=103230
| Assignee | ||
Comment 2•1 month ago
|
||
CI Results
Ran 0 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI
Total 1 tests and 3 subtests
Status Summary
Firefox
OK : 1
PASS: 1
FAIL: 2
Chrome
OK : 1
PASS: 3
Safari
OK : 1
PASS: 3
Links
Details
Firefox-only Failures
- /html/cross-origin-opener-policy/navigate-top-to-aboutblank.https.html [wpt.fyi]
- Navigate top to about:blank from iframe with opener COOP: |header(Cross-Origin-Opener-Policy,same-origin), iframe origin: https://www1.web-platform.test:8443:
FAIL - Navigate top to about:blank from iframe with opener COOP: |header(Cross-Origin-Opener-Policy,same-origin-allow-popups), iframe origin: https://www1.web-platform.test:8443:
FAIL
- Navigate top to about:blank from iframe with opener COOP: |header(Cross-Origin-Opener-Policy,same-origin), iframe origin: https://www1.web-platform.test:8443:
New Tests That Don't Pass
- /html/cross-origin-opener-policy/navigate-top-to-aboutblank.https.html [wpt.fyi]
- Navigate top to about:blank from iframe with opener COOP: |header(Cross-Origin-Opener-Policy,same-origin), iframe origin: https://www1.web-platform.test:8443:
FAIL(Chrome:PASS, Safari:PASS) - Navigate top to about:blank from iframe with opener COOP: |header(Cross-Origin-Opener-Policy,same-origin-allow-popups), iframe origin: https://www1.web-platform.test:8443:
FAIL(Chrome:PASS, Safari:PASS)
- Navigate top to about:blank from iframe with opener COOP: |header(Cross-Origin-Opener-Policy,same-origin), iframe origin: https://www1.web-platform.test:8443:
https://hg.mozilla.org/mozilla-central/rev/a0996e288840
https://hg.mozilla.org/mozilla-central/rev/25a4705da8fa
Description
•