Skip to content
This repository was archived by the owner on Jul 9, 2025. It is now read-only.

Commit 0578eac

Browse files
blu25moz-wptsync-bot
authored andcommitted
Bug 1915756 [wpt PR 47878] - Refactor some sandbox top-navigation tests as browsertests., a=testonly
Automatic update from web-platform-tests Refactor some sandbox top-navigation tests as browsertests. A series of tentative WPTs were written to test updates to our framebusting interventions. Some of the tests written test non-standard behavior, and have been resulting in failures when other browsers (who have not implemented our framebusting interventions) try to run them. There are also issues with some of the tests themselves when running in headless mode, as they require giving user activation to a subframe in a separate window the test opens, which is something headless mode doesn't currently support. To fix both of these problems, this CL refactors the problematic tests into browser tests. Most of the WPTs are staying as is, since they test standard behavior and don't have compatibility issues with headless mode. The following tests are being refactored into browser tests: * sandbox-top-navigation-cross-origin-escalate * now FramebustingFromPrivilegeEscalationFails * sandbox-top-navigation-child-cross-origin-delivered * now FramebustingFromDeliveredFlagsFails * sandbox-top-navigation-cross-site * now FramebustingAfterCrossSiteNavigationFails * sandbox-top-navigation-grandchild-sandboxed-escalate * now FramebustingFromGrandchildPrivilegeEscalationFails * sandbox-top-navigation-same-site-no-activation * now FramebustingAfterSameSiteNavigationWithoutUserActivationFails * sandbox-top-navigation-same-site * now FramebustingAfterSameSiteNavigationSucceeds The following tests have duplicates and are being removed altogether: * sandbox-top-navigation-child-frame-both * duplicate of iframe_sandbox_allow_top_navigation-3 * sandbox-top-navigation-child-frame * duplicate of iframe_sandbox_allow_top_navigation-1 * sandbox-top-navigation-grandchild-unsandboxed * duplicate of sandbox-top-navigation-grandchild-unsandboxed-cross-origin-parent * sandbox-top-navigation-user-activation-no-sticky * duplicate of iframe_sandbox_allow_top_navigation_by_user_activation_without_user_gesture * sandbox-top-navigation-user-activation-sticky * duplicate of iframe_sandbox_allow_top_navigation_by_user_activation-manual The following tests rely on manual behavior and, while not being removed, are getting an equivalent browser test: * iframe_sandbox_allow_top_navigation_by_user_activation_without_user_gesture * now FramebustingWithAllowTopNavigationByUserActivation * iframe_sandbox_allow_top_navigation_by_user_activation-manual * also now FramebustingWithAllowTopNavigationByUserActivation Bug: 347782854 Change-Id: I3b39a9d51db3dd725c8a88eac0bb464fa4753c04 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5813532 Reviewed-by: Nasko Oskov <[email protected]> Commit-Queue: Liam Brady <[email protected]> Cr-Commit-Position: refs/heads/main@{#1348945} -- wpt-commits: daf9128aee6e3559f3dea882ae81d451d11500f2 wpt-pr: 47878
1 parent 2b0a530 commit 0578eac

12 files changed

+1
-223
lines changed

testing/web-platform/tests/html/semantics/embedded-content/the-iframe-element/sandbox-top-navigation-child-cross-origin-delivered.tentative.sub.window.js

Lines changed: 0 additions & 18 deletions
This file was deleted.

testing/web-platform/tests/html/semantics/embedded-content/the-iframe-element/sandbox-top-navigation-child-delivered.tentative.sub.window.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
promise_test(async t => {
1313
const main = await setupTest();
1414
const iframe_1 = await createNestedIframe(
15-
main, 'HTTP_ORIGIN', '', 'allow-top-navigation allow-same-origin');
15+
main, 'HTTP_ORIGIN', '', 'allow-top-navigation allow-same-origin');
1616

1717
await attemptTopNavigation(iframe_1, true);
1818
}, 'A same-origin frame with delivered sandbox flags can navigate top');

testing/web-platform/tests/html/semantics/embedded-content/the-iframe-element/sandbox-top-navigation-child-frame-both.tentative.sub.window.js

Lines changed: 0 additions & 20 deletions
This file was deleted.

testing/web-platform/tests/html/semantics/embedded-content/the-iframe-element/sandbox-top-navigation-child-frame.tentative.sub.window.js

Lines changed: 0 additions & 18 deletions
This file was deleted.

testing/web-platform/tests/html/semantics/embedded-content/the-iframe-element/sandbox-top-navigation-cross-origin-escalate.tentative.sub.window.js

Lines changed: 0 additions & 20 deletions
This file was deleted.

testing/web-platform/tests/html/semantics/embedded-content/the-iframe-element/sandbox-top-navigation-cross-site.tentative.sub.window.js

Lines changed: 0 additions & 22 deletions
This file was deleted.

testing/web-platform/tests/html/semantics/embedded-content/the-iframe-element/sandbox-top-navigation-grandchild-sandboxed-escalate.tentative.sub.window.js

Lines changed: 0 additions & 20 deletions
This file was deleted.

testing/web-platform/tests/html/semantics/embedded-content/the-iframe-element/sandbox-top-navigation-grandchild-unsandboxed.tentative.sub.window.js

Lines changed: 0 additions & 18 deletions
This file was deleted.

testing/web-platform/tests/html/semantics/embedded-content/the-iframe-element/sandbox-top-navigation-same-site-no-activation.tentative.sub.window.js

Lines changed: 0 additions & 23 deletions
This file was deleted.

testing/web-platform/tests/html/semantics/embedded-content/the-iframe-element/sandbox-top-navigation-same-site.tentative.sub.window.js

Lines changed: 0 additions & 24 deletions
This file was deleted.

0 commit comments

Comments
 (0)