diff --git a/html/cross-origin-opener-policy/coop-csp-sandbox-navigate.https.html b/html/cross-origin-opener-policy/coop-csp-sandbox-navigate.https.html
new file mode 100644
index 00000000000000..e9e83072ce5f15
--- /dev/null
+++ b/html/cross-origin-opener-policy/coop-csp-sandbox-navigate.https.html
@@ -0,0 +1,25 @@
+
+
CSP sandbox popup navigate to Cross-Origin-Opener-Policy document should work
+
+
+
+
+
diff --git a/html/cross-origin-opener-policy/resources/common.js b/html/cross-origin-opener-policy/resources/common.js
index 8a3cd133734dc3..85d548c4629ae2 100644
--- a/html/cross-origin-opener-policy/resources/common.js
+++ b/html/cross-origin-opener-policy/resources/common.js
@@ -92,4 +92,16 @@ function run_coop_test_iframe (documentTitle, iframe_origin, popup_origin, popup
});
document.body.append(frame);
}, `${documentTitle} with ${iframe_origin.name} iframe opening popup a ${popup_origin.name} with COOP: ${popup_coop}`);
-}
\ No newline at end of file
+}
+
+// Need to wait until the page is fully loaded before navigating
+// so that it creates a history entry properly.
+const fullyLoaded = new Promise((resolve, reject) => {
+ addEventListener('load', () => {
+ requestAnimationFrame(() => {
+ requestAnimationFrame(() => {
+ resolve();
+ });
+ });
+ });
+});
diff --git a/html/cross-origin-opener-policy/resources/coop-coep.py b/html/cross-origin-opener-policy/resources/coop-coep.py
index e0a3d90050a624..dea3724e9df0a2 100644
--- a/html/cross-origin-opener-policy/resources/coop-coep.py
+++ b/html/cross-origin-opener-policy/resources/coop-coep.py
@@ -26,23 +26,13 @@ def main(request, response):
+
+
"""