-
Notifications
You must be signed in to change notification settings - Fork 3.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Prerender: Clean up arguments of create_prerendered_page() used in WPTs
This CL cleans up create_prerendered_page() helper used in WPTs to trigger prerendering. This is a preparation for adding No-Vary-Search (NVS) header WPTs with speculation rules prerendering. This CL merges `opt` and `init_opt` arguments on create_prerendered_page() into one `params` Object argument. This object contains `initiator`, `prerendering`, and `activating` keys, and their values are URLSearchParams. These search params are attached to initiator navigation, prerendering navigation, and activating navigation respectively. In this CL, `activating` is actually not used, but this will be necessary for NVS header WPTs to be added by follow-up CLs so that the tests can specify varied search params. This CL also repurposes `opt` argument for controlling behavior of the helper. Before this CL, the helper checked `init_opt.prefetch` to decide if prefetch should be triggered before prerendering. This was confusing as `init_opt` was also used for specifying search params of the initiator page. After this CL, `opt` is specialized for controlling such behavior and `prefetch` is specified there. This should be less confusing. Change-Id: I158724c6bf996cfcc03a353133267809ea1e4999 Bug: 340928303 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5550431 Reviewed-by: Domenic Denicola <[email protected]> Commit-Queue: Hiroki Nakagawa <[email protected]> Cr-Commit-Position: refs/heads/main@{#1303551}
- Loading branch information
1 parent
a05ac39
commit 495da8a
Showing
5 changed files
with
73 additions
and
40 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters