Skip to content
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

RFC 86: fetch_tests_from_prefixed_local_storage #86

Conversation

hiroshige-g
Copy link

@hiroshige-g hiroshige-g commented Jun 21, 2021

@hiroshige-g hiroshige-g force-pushed the fetch_tests_from_prefixed_local_storage branch 2 times, most recently from d8dc2b8 to ff0bf94 Compare June 22, 2021 00:00
@hiroshige-g hiroshige-g force-pushed the fetch_tests_from_prefixed_local_storage branch from ff0bf94 to 1cd5066 Compare June 22, 2021 00:02
@annevk
Copy link
Member

annevk commented Jun 22, 2021

This also seems useful for testing COOP. cc @ArthurSonzogni @mystor

@ArthurSonzogni
Copy link
Member

ArthurSonzogni commented Jun 22, 2021

This also seems useful for testing COOP. cc @ArthurSonzogni @mystor

For COOP reporting, COEP credentialless, and the latest COOP tests, we have switched toward the alternative 1 discussed in this RFC: Fetch API + server-side stash. Specifically those files: (dispatcher.js, dispatcher.py, executor.html, executor.js)

This is working very well. I tend to use them for all my tests, even when it is not strictly required, because it is easier to write tests this way when there are multiple ExecutionContext. I am happy. I can write all the logic in a single HTML file "from the outside" without creating many helper files.

The solution above is universal. It supports any ExecutionContext from any origin and any status. For COOP, testing with cross-origin document is essential. For anonymous iframe or partitioned cache, relying on the localStorage seems problematic.

So, I don't believe I would use this proposal myself, but I agree this might be useful, especially given that open fetch requests are preventing a page from entering the BackForwardCache.

Note that you can use "await" with fetch in await send(uuid, message) & await receive(uuid) to wait for the fetch request to resolve before navigating away from the document. This might resolve partially the problems you have with fetch+BackForwardCache, but maybe not always.

@hiroshige-g
Copy link
Author

@ArthurSonzogni, thanks for the information! The executor approach looks promising, as it is a concrete design of "from the outside" style testing. I'll try rewriting my tests using the executor approach to see how it works in BFCache cases. Still I might need additional logic to ensure there are no outgoing fetches during navigation, but hopefully I might resolve issues around my service worker related tests.

@hiroshige-g
Copy link
Author

cc @nhiroki; WDYT the COEP's approach in the context of prerender tests?

@jgraham
Copy link
Contributor

jgraham commented Jun 24, 2021

I think this is clearly a use case that needs addressing. My guess is that using the server is going to be the most effective mechanim, since that allows us to bypass all origin restrictions. If we decide to adopt that approach I'd like to see it integrated into testharness.js and documented as a first class API.

@hiroshige-g hiroshige-g changed the title RFC: fetch_tests_from_prefixed_local_storage RFC 86: fetch_tests_from_prefixed_local_storage Jul 9, 2021
@hiroshige-g
Copy link
Author

I rewrote my tests using the COEP executor framework (web-platform-tests/wpt#28950 and https://chromium-review.googlesource.com/c/chromium/src/+/2798554/), and the rewritten tests looks better, especially serviceworker-related ones. So I'll use the COEP framework and withdraw this RFC.
Thank you all for very helpful comments!

@hiroshige-g
Copy link
Author

(I don't have clear ideas about integrating the COEP approach into testharness.js though; maybe moving the files to /common/?)

@Ms2ger Ms2ger closed this Jul 9, 2021
@ArthurSonzogni
Copy link
Member

I received PR to move the COEP:credentialless implementation to /common/dispatcher/.
That's basically the following API:

  • send(uuid, message)
  • receive(uuid)

This provides a message queue, callable from any context.

There are also some dummy HTML for document / JS for worker, executing arbitrary code sent to them by the test driver.

I will be happy to land this after various suggestion. However I shouldn't be the only one making this decision. So I am checking, do we have reached some kind of agreement here?
Should a new RFC be created, or we can continue on this one? Do you have any suggestions?

@jgraham
Copy link
Contributor

jgraham commented Jul 16, 2021

My only concern here is that this is still ending up as a largely undocumented thing you just have to know about. I'm happy for that PR to land, but I wonder if we should be looking to move it into testharness.js and maybe add some API surface like fetch_tests_from_server that encapsulate common patterns. Those changes would indeed require an RFC. In the meantime I might request that we at least add some documentation under docs for the functionality.

@hiroshige-g
Copy link
Author

I imagine that the API would be more like a remote procedure call library outside testharness.js (i.e. more sophisticasted version of send(), like evalOn I'm adding at web-platform-tests/wpt#28950 plus error handling, plumbing exceptions and promise resolution/rejection to the caler, etc.), and checking the remote call results using assert_*().

fetch_tests_from_prefixed_local_storage or fetch_tests_from_server style would be more complicated, because if there are multiple pages involved (which is the case in BFCache tests), there are no single page that hosts e.g. async_test() object, unlike existing fetch_tests_from_*.
Introducing something to host the test object persistently (e.g. a test object stored in server side) would resolve this issue, but it might also complicates the tests.
Also, Switching from fetch_tests_from_prefixed_local_storage style (where assert_*() is called on the isolated Window to be navigated and results are plumbed to the main Window using fetch_tests_from_prefixed_local_storage) to the COEP executor stye (where assert_*() is called on the persistent main Window) made the tests much easier to write.

I haven't come up with any other ideas around testharness.js integration for now... any thoughts?

@hiroshige-g
Copy link
Author

Do you have specific "largely undocumented thing" in mind?
Some of undocumented things in my mind that I'm going to improve / document are error handling (currently mostly not handled) and synchronization (e.g. whether await send() waits for completion of injected code (answer: no)), and I'm happy to add more documentation.

@jgraham
Copy link
Contributor

jgraham commented Jul 16, 2021

In the sense that afaict nothing under https://web-platform-tests.org/writing-tests/index.html covers this functionality. So not just code-level documentation but something that allows people to discover the feature exists in the first place.

@hiroshige-g
Copy link
Author

Sounds reasonable (I also didn't know the COEP executor before this thread).

On the other hand, there are a bunch of other test helpers, frameworks, etc. in WPT, that are not documented in https://web-platform-tests.org/writing-tests.
Is this executor framework enough special to be documented there? (if so perhaps we need another RFC?)

@jgraham
Copy link
Contributor

jgraham commented Jul 16, 2021

The fact that it's been useful enough for testing two apparently unrelated features suggests to me that it's worth documenting and supporting as an "official" feature.

In terms of the API, I wonder if there's something slightly higher level where instead of passing a token around you get some kind of RemoteWindow object that you're able to message, and the library handles the token management as far as possible. I haven't thought about it in detail, but there could be oppertunities to integrate with the debug logging in testharness.js to help disgnose test failures where this feature is used.

@hiroshige-g
Copy link
Author

Thanks for comments, I'll prepare documentation in writing-tests later.

As for API, I drafted a CL https://chromium-review.googlesource.com/c/chromium/src/+/3055392 to introduce wrapper classes.

@jgraham
Copy link
Contributor

jgraham commented Jul 27, 2021

Thanks, that looks nice!

I think this stuff requires an RFC to get consensus on the API shape, not just review in the Chromium review system.

I've been looking at the problem for another angle; testdriver has the ability to execute actions in another context, but that didn't work well cross-origin (or at least didn't work for noopener cases). Since we don't currently have the ability to use WebDriver window ids directly, it makes sense to share the same kind of UUID system, and maybe same frontend, for testdriver and for this message passing infrastructure. I'll put that up as a draft PR soon, but I'd really like us to avoid landing any of this stuff before we go through the RFC process.

@jgraham
Copy link
Contributor

jgraham commented Jul 27, 2021

OK, so I created a draft PR and a set of RFCs with a variation on this theme. It doesn't currently have all the features of dispatcher.py, but it's a good (set of) places to have the discussion going forward:

@hiroshige-g
Copy link
Author

Thank you for drafting the concrete PRs/RFCs! I'll try migrating a couple of BFCache tests to the testdriver version to see how it works.

chromium-wpt-export-bot pushed a commit to web-platform-tests/wpt that referenced this pull request Sep 16, 2021
…e tests + helpers

This PR adds `RemoteContext.execute_script()` and its documentation
in `/common/dispatcher/`.
This is based on with `execute_script()`-related parts of RFCs 88/89/91:

- web-platform-tests/rfcs#88
- web-platform-tests/rfcs#89
- web-platform-tests/rfcs#91

and addresses comments:

- web-platform-tests/rfcs#86 (comment)
- #28950 (comment)

plus additional clarifications around navigation,
minus `testdriver` integration (so this PR is implemented using
`send()`/`receive()` in `/common/dispatcher/`),
minus web-platform-tests/rfcs#90
(so this PR leaves `send()`/`receive()` as-is).

This PR also adds back-forward cache WPTs (basic event firing tests),
as well as BFCache-specific helpers, based on
`RemoteContext.execute_script()`.

Design doc:
https://docs.google.com/document/d/1p3G-qNYMTHf5LU9hykaXcYtJ0k3wYOwcdVKGeps6EkU/edit?usp=sharing

Bug: 1107415
Change-Id: I034f9f5376dc3f9f32ca0b936dbd06e458c9160b
chromium-wpt-export-bot pushed a commit to web-platform-tests/wpt that referenced this pull request Sep 16, 2021
…e tests + helpers

This PR adds `RemoteContext.execute_script()` and its documentation
in `/common/dispatcher/`.
This is based on with `execute_script()`-related parts of RFCs 88/89/91:

- web-platform-tests/rfcs#88
- web-platform-tests/rfcs#89
- web-platform-tests/rfcs#91

and addresses comments:

- web-platform-tests/rfcs#86 (comment)
- #28950 (comment)

plus additional clarifications around navigation,
minus `testdriver` integration (so this PR is implemented using
`send()`/`receive()` in `/common/dispatcher/`),
minus web-platform-tests/rfcs#90
(so this PR leaves `send()`/`receive()` as-is).

This PR also adds back-forward cache WPTs (basic event firing tests),
as well as BFCache-specific helpers, based on
`RemoteContext.execute_script()`.

Design doc:
https://docs.google.com/document/d/1p3G-qNYMTHf5LU9hykaXcYtJ0k3wYOwcdVKGeps6EkU/edit?usp=sharing

Bug: 1107415
Change-Id: I034f9f5376dc3f9f32ca0b936dbd06e458c9160b
chromium-wpt-export-bot pushed a commit to web-platform-tests/wpt that referenced this pull request Sep 21, 2021
…e tests + helpers

This PR adds `RemoteContext.execute_script()` and its documentation
in `/common/dispatcher/`.
This is based on with `execute_script()`-related parts of RFCs 88/89/91:

- web-platform-tests/rfcs#88
- web-platform-tests/rfcs#89
- web-platform-tests/rfcs#91

and addresses comments:

- web-platform-tests/rfcs#86 (comment)
- #28950 (comment)

plus additional clarifications around navigation,
minus `testdriver` integration (so this PR is implemented using
`send()`/`receive()` in `/common/dispatcher/`),
minus web-platform-tests/rfcs#90
(so this PR leaves `send()`/`receive()` as-is).

This PR also adds back-forward cache WPTs (basic event firing tests),
as well as BFCache-specific helpers, based on
`RemoteContext.execute_script()`.

Design doc:
https://docs.google.com/document/d/1p3G-qNYMTHf5LU9hykaXcYtJ0k3wYOwcdVKGeps6EkU/edit?usp=sharing

Bug: 1107415
Change-Id: I034f9f5376dc3f9f32ca0b936dbd06e458c9160b
chromium-wpt-export-bot pushed a commit to web-platform-tests/wpt that referenced this pull request Sep 23, 2021
…e tests + helpers

This PR adds `RemoteContext.execute_script()` and its documentation
in `/common/dispatcher/`.
This is based on with `execute_script()`-related parts of RFCs 88/89/91:

- web-platform-tests/rfcs#88
- web-platform-tests/rfcs#89
- web-platform-tests/rfcs#91

and addresses comments:

- web-platform-tests/rfcs#86 (comment)
- #28950 (comment)

plus additional clarifications around navigation,
minus `testdriver` integration (so this PR is implemented using
`send()`/`receive()` in `/common/dispatcher/`),
minus web-platform-tests/rfcs#90
(so this PR leaves `send()`/`receive()` as-is).

This PR also adds back-forward cache WPTs (basic event firing tests),
as well as BFCache-specific helpers, based on
`RemoteContext.execute_script()`.

Design doc:
https://docs.google.com/document/d/1p3G-qNYMTHf5LU9hykaXcYtJ0k3wYOwcdVKGeps6EkU/edit?usp=sharing

Bug: 1107415
Change-Id: I034f9f5376dc3f9f32ca0b936dbd06e458c9160b
chromium-wpt-export-bot pushed a commit to web-platform-tests/wpt that referenced this pull request Sep 23, 2021
…e tests + helpers

This PR adds `RemoteContext.execute_script()` and its documentation
in `/common/dispatcher/`.
This is based on with `execute_script()`-related parts of RFCs 88/89/91:

- web-platform-tests/rfcs#88
- web-platform-tests/rfcs#89
- web-platform-tests/rfcs#91

and addresses comments:

- web-platform-tests/rfcs#86 (comment)
- #28950 (comment)

plus additional clarifications around navigation,
minus `testdriver` integration (so this PR is implemented using
`send()`/`receive()` in `/common/dispatcher/`),
minus web-platform-tests/rfcs#90
(so this PR leaves `send()`/`receive()` as-is).

This PR also adds back-forward cache WPTs (basic event firing tests),
as well as BFCache-specific helpers, based on
`RemoteContext.execute_script()`.

Design doc:
https://docs.google.com/document/d/1p3G-qNYMTHf5LU9hykaXcYtJ0k3wYOwcdVKGeps6EkU/edit?usp=sharing

Bug: 1107415
Change-Id: I034f9f5376dc3f9f32ca0b936dbd06e458c9160b
chromium-wpt-export-bot pushed a commit to web-platform-tests/wpt that referenced this pull request Sep 29, 2021
…e tests + helpers

This PR adds `RemoteContext.execute_script()` and its documentation
in `/common/dispatcher/`.
This is based on with `execute_script()`-related parts of RFCs 88/89/91:

- web-platform-tests/rfcs#88
- web-platform-tests/rfcs#89
- web-platform-tests/rfcs#91

and addresses comments:

- web-platform-tests/rfcs#86 (comment)
- #28950 (comment)

plus additional clarifications around navigation,
minus `testdriver` integration (so this PR is implemented using
`send()`/`receive()` in `/common/dispatcher/`),
minus web-platform-tests/rfcs#90
(so this PR leaves `send()`/`receive()` as-is).

This PR also adds back-forward cache WPTs (basic event firing tests),
as well as BFCache-specific helpers, based on
`RemoteContext.execute_script()`.

Design doc:
https://docs.google.com/document/d/1p3G-qNYMTHf5LU9hykaXcYtJ0k3wYOwcdVKGeps6EkU/edit?usp=sharing

Bug: 1107415
Change-Id: I034f9f5376dc3f9f32ca0b936dbd06e458c9160b
chromium-wpt-export-bot pushed a commit to web-platform-tests/wpt that referenced this pull request Oct 4, 2021
…e tests + helpers

This PR adds `RemoteContext.execute_script()` and its documentation
in `/common/dispatcher/`.
This is based on with `execute_script()`-related parts of RFCs 88/89/91:

- web-platform-tests/rfcs#88
- web-platform-tests/rfcs#89
- web-platform-tests/rfcs#91

and addresses comments:

- web-platform-tests/rfcs#86 (comment)
- #28950 (comment)

plus additional clarifications around navigation,
minus `testdriver` integration (so this PR is implemented using
`send()`/`receive()` in `/common/dispatcher/`),
minus web-platform-tests/rfcs#90
(so this PR leaves `send()`/`receive()` as-is).

This PR also adds back-forward cache WPTs (basic event firing tests),
as well as BFCache-specific helpers, based on
`RemoteContext.execute_script()`.

Design doc:
https://docs.google.com/document/d/1p3G-qNYMTHf5LU9hykaXcYtJ0k3wYOwcdVKGeps6EkU/edit?usp=sharing

Bug: 1107415
Change-Id: I034f9f5376dc3f9f32ca0b936dbd06e458c9160b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2885636
Reviewed-by: Rakina Zata Amni <[email protected]>
Reviewed-by: Arthur Sonzogni <[email protected]>
Commit-Queue: Hiroshige Hayashizaki <[email protected]>
Cr-Commit-Position: refs/heads/main@{#927566}
blueboxd pushed a commit to blueboxd/chromium-legacy that referenced this pull request Oct 4, 2021
…e tests + helpers

This PR adds `RemoteContext.execute_script()` and its documentation
in `/common/dispatcher/`.
This is based on with `execute_script()`-related parts of RFCs 88/89/91:

- web-platform-tests/rfcs#88
- web-platform-tests/rfcs#89
- web-platform-tests/rfcs#91

and addresses comments:

- web-platform-tests/rfcs#86 (comment)
- web-platform-tests/wpt#28950 (comment)

plus additional clarifications around navigation,
minus `testdriver` integration (so this PR is implemented using
`send()`/`receive()` in `/common/dispatcher/`),
minus web-platform-tests/rfcs#90
(so this PR leaves `send()`/`receive()` as-is).

This PR also adds back-forward cache WPTs (basic event firing tests),
as well as BFCache-specific helpers, based on
`RemoteContext.execute_script()`.

Design doc:
https://docs.google.com/document/d/1p3G-qNYMTHf5LU9hykaXcYtJ0k3wYOwcdVKGeps6EkU/edit?usp=sharing

Bug: 1107415
Change-Id: I034f9f5376dc3f9f32ca0b936dbd06e458c9160b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2885636
Reviewed-by: Rakina Zata Amni <[email protected]>
Reviewed-by: Arthur Sonzogni <[email protected]>
Commit-Queue: Hiroshige Hayashizaki <[email protected]>
Cr-Commit-Position: refs/heads/main@{#927566}
past pushed a commit to web-platform-tests/wpt that referenced this pull request Oct 6, 2021
…e tests + helpers (#28950)

This PR adds `RemoteContext.execute_script()` and its documentation
in `/common/dispatcher/`.
This is based on with `execute_script()`-related parts of RFCs 88/89/91:

- web-platform-tests/rfcs#88
- web-platform-tests/rfcs#89
- web-platform-tests/rfcs#91

and addresses comments:

- web-platform-tests/rfcs#86 (comment)
- #28950 (comment)

plus additional clarifications around navigation,
minus `testdriver` integration (so this PR is implemented using
`send()`/`receive()` in `/common/dispatcher/`),
minus web-platform-tests/rfcs#90
(so this PR leaves `send()`/`receive()` as-is).

This PR also adds back-forward cache WPTs (basic event firing tests),
as well as BFCache-specific helpers, based on
`RemoteContext.execute_script()`.

Design doc:
https://docs.google.com/document/d/1p3G-qNYMTHf5LU9hykaXcYtJ0k3wYOwcdVKGeps6EkU/edit?usp=sharing

Bug: 1107415
Change-Id: I034f9f5376dc3f9f32ca0b936dbd06e458c9160b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2885636
Reviewed-by: Rakina Zata Amni <[email protected]>
Reviewed-by: Arthur Sonzogni <[email protected]>
Commit-Queue: Hiroshige Hayashizaki <[email protected]>
Cr-Commit-Position: refs/heads/main@{#927566}

Co-authored-by: Hiroshige Hayashizaki <[email protected]>
moz-v2v-gh pushed a commit to mozilla/gecko-dev that referenced this pull request Oct 13, 2021
…cript()` and add basic BFCache tests + helpers, a=testonly

Automatic update from web-platform-tests
[WPT] Introduce `RemoteContext.execute_script()` and add basic BFCache tests + helpers (#28950)

This PR adds `RemoteContext.execute_script()` and its documentation
in `/common/dispatcher/`.
This is based on with `execute_script()`-related parts of RFCs 88/89/91:

- web-platform-tests/rfcs#88
- web-platform-tests/rfcs#89
- web-platform-tests/rfcs#91

and addresses comments:

- web-platform-tests/rfcs#86 (comment)
- web-platform-tests/wpt#28950 (comment)

plus additional clarifications around navigation,
minus `testdriver` integration (so this PR is implemented using
`send()`/`receive()` in `/common/dispatcher/`),
minus web-platform-tests/rfcs#90
(so this PR leaves `send()`/`receive()` as-is).

This PR also adds back-forward cache WPTs (basic event firing tests),
as well as BFCache-specific helpers, based on
`RemoteContext.execute_script()`.

Design doc:
https://docs.google.com/document/d/1p3G-qNYMTHf5LU9hykaXcYtJ0k3wYOwcdVKGeps6EkU/edit?usp=sharing

Bug: 1107415
Change-Id: I034f9f5376dc3f9f32ca0b936dbd06e458c9160b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2885636
Reviewed-by: Rakina Zata Amni <[email protected]>
Reviewed-by: Arthur Sonzogni <[email protected]>
Commit-Queue: Hiroshige Hayashizaki <[email protected]>
Cr-Commit-Position: refs/heads/main@{#927566}

Co-authored-by: Hiroshige Hayashizaki <[email protected]>
--

wpt-commits: 2947a57c382cd0886906a8cbb6bad702d70a7976
wpt-pr: 28950
jamienicol pushed a commit to jamienicol/gecko that referenced this pull request Oct 14, 2021
…cript()` and add basic BFCache tests + helpers, a=testonly

Automatic update from web-platform-tests
[WPT] Introduce `RemoteContext.execute_script()` and add basic BFCache tests + helpers (#28950)

This PR adds `RemoteContext.execute_script()` and its documentation
in `/common/dispatcher/`.
This is based on with `execute_script()`-related parts of RFCs 88/89/91:

- web-platform-tests/rfcs#88
- web-platform-tests/rfcs#89
- web-platform-tests/rfcs#91

and addresses comments:

- web-platform-tests/rfcs#86 (comment)
- web-platform-tests/wpt#28950 (comment)

plus additional clarifications around navigation,
minus `testdriver` integration (so this PR is implemented using
`send()`/`receive()` in `/common/dispatcher/`),
minus web-platform-tests/rfcs#90
(so this PR leaves `send()`/`receive()` as-is).

This PR also adds back-forward cache WPTs (basic event firing tests),
as well as BFCache-specific helpers, based on
`RemoteContext.execute_script()`.

Design doc:
https://docs.google.com/document/d/1p3G-qNYMTHf5LU9hykaXcYtJ0k3wYOwcdVKGeps6EkU/edit?usp=sharing

Bug: 1107415
Change-Id: I034f9f5376dc3f9f32ca0b936dbd06e458c9160b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2885636
Reviewed-by: Rakina Zata Amni <[email protected]>
Reviewed-by: Arthur Sonzogni <[email protected]>
Commit-Queue: Hiroshige Hayashizaki <[email protected]>
Cr-Commit-Position: refs/heads/main@{#927566}

Co-authored-by: Hiroshige Hayashizaki <[email protected]>
--

wpt-commits: 2947a57c382cd0886906a8cbb6bad702d70a7976
wpt-pr: 28950
Gabisampaio pushed a commit to Gabisampaio/wpt that referenced this pull request Nov 18, 2021
…e tests + helpers (web-platform-tests#28950)

This PR adds `RemoteContext.execute_script()` and its documentation
in `/common/dispatcher/`.
This is based on with `execute_script()`-related parts of RFCs 88/89/91:

- web-platform-tests/rfcs#88
- web-platform-tests/rfcs#89
- web-platform-tests/rfcs#91

and addresses comments:

- web-platform-tests/rfcs#86 (comment)
- web-platform-tests#28950 (comment)

plus additional clarifications around navigation,
minus `testdriver` integration (so this PR is implemented using
`send()`/`receive()` in `/common/dispatcher/`),
minus web-platform-tests/rfcs#90
(so this PR leaves `send()`/`receive()` as-is).

This PR also adds back-forward cache WPTs (basic event firing tests),
as well as BFCache-specific helpers, based on
`RemoteContext.execute_script()`.

Design doc:
https://docs.google.com/document/d/1p3G-qNYMTHf5LU9hykaXcYtJ0k3wYOwcdVKGeps6EkU/edit?usp=sharing

Bug: 1107415
Change-Id: I034f9f5376dc3f9f32ca0b936dbd06e458c9160b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2885636
Reviewed-by: Rakina Zata Amni <[email protected]>
Reviewed-by: Arthur Sonzogni <[email protected]>
Commit-Queue: Hiroshige Hayashizaki <[email protected]>
Cr-Commit-Position: refs/heads/main@{#927566}

Co-authored-by: Hiroshige Hayashizaki <[email protected]>
mjfroman pushed a commit to mjfroman/moz-libwebrtc-third-party that referenced this pull request Oct 14, 2022
…e tests + helpers

This PR adds `RemoteContext.execute_script()` and its documentation
in `/common/dispatcher/`.
This is based on with `execute_script()`-related parts of RFCs 88/89/91:

- web-platform-tests/rfcs#88
- web-platform-tests/rfcs#89
- web-platform-tests/rfcs#91

and addresses comments:

- web-platform-tests/rfcs#86 (comment)
- web-platform-tests/wpt#28950 (comment)

plus additional clarifications around navigation,
minus `testdriver` integration (so this PR is implemented using
`send()`/`receive()` in `/common/dispatcher/`),
minus web-platform-tests/rfcs#90
(so this PR leaves `send()`/`receive()` as-is).

This PR also adds back-forward cache WPTs (basic event firing tests),
as well as BFCache-specific helpers, based on
`RemoteContext.execute_script()`.

Design doc:
https://docs.google.com/document/d/1p3G-qNYMTHf5LU9hykaXcYtJ0k3wYOwcdVKGeps6EkU/edit?usp=sharing

Bug: 1107415
Change-Id: I034f9f5376dc3f9f32ca0b936dbd06e458c9160b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2885636
Reviewed-by: Rakina Zata Amni <[email protected]>
Reviewed-by: Arthur Sonzogni <[email protected]>
Commit-Queue: Hiroshige Hayashizaki <[email protected]>
Cr-Commit-Position: refs/heads/main@{#927566}
NOKEYCHECK=True
GitOrigin-RevId: 66dbd4c686fec8d07c493c6283ab906c57752e39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants