[rsaFor] Add early scaffolding and test coverage
This is early stage work. Future updates will begin making calls to
PermissionService with the site override, integrate with First-Party
Sets, and further instrument the code. Note that this work is also
pending further development of the specification; the goal is to have a
working prototype, but it is and will remain subject to change for some
time.
Bug: 1351540
Change-Id: I13694ef2b61475c247d1067ef98736eb7aecd000
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3826292
Reviewed-by: Dominic Farolino <[email protected]>
Reviewed-by: Mike West <[email protected]>
Commit-Queue: Matt Reichhoff <[email protected]>
Reviewed-by: Lei Zhang <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1037269}
diff --git a/chrome/browser/net/storage_test_utils.h b/chrome/browser/net/storage_test_utils.h
index bfabd381..5c8db81 100644
--- a/chrome/browser/net/storage_test_utils.h
+++ b/chrome/browser/net/storage_test_utils.h
@@ -35,6 +35,11 @@
// document.requestStorageAccess(). Returns true if the promise resolves; false
// if it rejects.
bool RequestStorageAccessForFrame(content::RenderFrameHost* frame);
+// Helper to request storage access with a site override for a frame using
+// document.requestStorageAccessForSite(site). Returns true if the promise
+// resolves; false if it rejects.
+bool RequestStorageAccessForSite(content::RenderFrameHost* frame,
+ const std::string& site);
// Helper to see if a frame currently has storage access using
// document.hasStorageAccess(). Returns true if the promise resolves with a
// value of true; false otherwise.