Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[COOP] Use /set-headers? in test instead of specific files.
There are 4 headers: - Cross-Origin-Opener-Policy: 3 values. - Cross-Origin-Opener-Policy-Report-Only: 3 values. - Cross-Origin-Embedder-Policy: 2 values. - Cross-Origin-Embedder-Policy-Report-Only: 2 values. I was asked to produces tests about the different configurations. There are up to 24 possibilities. Currently, we are producing a new test file for every combinaison, like: page_with_coop_and_coep.html{,mock-http-headers} If we want to test further, the number of files is going to grow quickly. Moreover we would have to produce very complex name: page_with_coop_ro_same_origin_allow_opener_coop_same_origin_coep.html It would be better if we could specify the headers to use in tests. This is possible thanks to the "/set-headers?" handler. The file above can be replaced by the path: "/set-headers?" "Cross-Origin-Opener-Policy: same-origin-allow-popups&" "Cross-Origin-Opener-Policy-Report-Only: same-origin&" "Cross-Origin-EmbedderPolicy: require-corp" This is much more readable and flexible. This patch deletes all the current files we have and use "/set-header?" instead. Bug: chromium:1090273 Change-Id: I67195f0940c4bb1a873014fe69c49321dcf76774 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2279803 Reviewed-by: Pâris Meuleman <pmeuleman@chromium.org> Commit-Queue: Arthur Sonzogni <arthursonzogni@chromium.org> Cr-Commit-Position: refs/heads/master@{#785693}
- Loading branch information