[Extensions] Use fetch in PermissionsApiTest.OptionalPermissions* tests.
This CL changes PermissionsApiTest.OptionalPermissions and PermissionsApiTest.OptionalPermissionsAutoConfirm tests to use fetch API instead of XHR. This CL also defers removeOrigin() sub-test's permission removal to after the first request/fetch's completion: - This makes the test "theoretically" correct, as the permission should not be removed before the first request/fetch is issued. - This ensures that the test is correct after it uses fetch API. This is probably because fetch is async (compared to XHR). This CL will let SW based version of these tests easy to implement. Bug: None Test: None Change-Id: I139888953f30f0430d558ccce3cd9331af624fb4 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2516391Reviewed-by:David Bertoni <dbertoni@chromium.org> Commit-Queue: Istiaque Ahmed <lazyboy@chromium.org> Cr-Commit-Position: refs/heads/master@{#823743}
Showing
Please register or sign in to comment