-
Notifications
You must be signed in to change notification settings - Fork 3.6k
Add tests for redacted location.ancestorOrigins https://github.com/whatwg/html/pull/11560 #56224
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add tests for redacted location.ancestorOrigins https://github.com/whatwg/html/pull/11560 #56224
Conversation
...browsers/history/the-location-interface/resources/location-ancestor-origins-create-iframe.js
Outdated
Show resolved
Hide resolved
...ers/history/the-location-interface/resources/location-ancestor-origins-recursive-iframe.html
Show resolved
Hide resolved
...ers/history/the-location-interface/resources/location-ancestor-origins-recursive-iframe.html
Outdated
Show resolved
Hide resolved
...ers/history/the-location-interface/resources/location-ancestor-origins-recursive-iframe.html
Outdated
Show resolved
Hide resolved
html/browsers/history/the-location-interface/location-ancestor-origins.sub.html
Show resolved
Hide resolved
html/browsers/history/the-location-interface/location-ancestor-origins.tentative.sub.html
Outdated
Show resolved
Hide resolved
3b36668 to
1357a38
Compare
html/browsers/history/the-location-interface/location-ancestor-origins.sub.html
Outdated
Show resolved
Hide resolved
...ers/history/the-location-interface/resources/location-ancestor-origins-recursive-iframe.html
Outdated
Show resolved
Hide resolved
1357a38 to
b81b1b0
Compare
- Tests toggling of 'masked' in the algorithm. - Tests mutating policy on iframe and then having a grandchild browsing context be created. - Tests sandboxing so that all origins become null below it.
b81b1b0 to
2d6e76c
Compare
|
I added about:blank tests to this WPT, as they were useful when implementing this feature in Gecko. Technically, from a spec perspective an about:blank or a normal document aren't different, but there could be implementation details that can make these tests useful. Should we keep it or should I move it to a gecko-only repo? |
|
Let's keep the about:blank tests in wpt. |
|
Marking this |
|
wpt sync PR #56685 |
Test written for the redacted location.ancestorOrigins spec.
Addresses all examples described in the PR for the spec in whatwg/html#11560.
Filed as a PR here because it was requested by @domfarolino to be able to comment on it.
Beyond the requested tag of loosening/tightening policy as requested by @domfarolino also added that doing this, should not affect grandchildren.
Test cases written in a declarative fashion:
description, frames: { name, src, iframeReferrerPolicy, options }[] , expected: string []
options is an object of: { sandbox?, target?, action?, value? }
Used to configure if the iframe should have the sandbox attribute.
target&&action&&valueis used to configure an iframe with a new attribute, or do something inside of a frame (target), like inserting a meta element.The reason for there being 3 iframes, instead of just 2, is to avoid changing anything in the top level document, which could potentially affect subsequent tests after it. This way, tear down is clean and simple between test cases.