embedder-require-corp.https.html (1462B)
1 <!DOCTYPE html> 2 <meta name="timeout" content="long"> 3 <title>Test COEP properties set for a Fenced Frame Tree</title> 4 <script src="/resources/testharness.js"></script> 5 <script src="/resources/testharnessreport.js"></script> 6 <script src="/common/get-host-info.sub.js"></script> 7 <script src="/common/utils.js"></script> 8 <script src="resources/utils.js"></script> 9 <script src="resources/embedder-policy.js"></script> 10 11 <body> 12 <script> 13 promise_test(async (t) => { 14 const uuid = token(); 15 const frame = setupTest("coep:require-corp", uuid); 16 const result = await nextValueFromServer(uuid); 17 assert_equals(result, "PASS", "embedded page has been loaded."); 18 }, "Create fencedframe with COEP:require-corp"); 19 20 promise_test(async (t) => { 21 const uuid = token(); 22 t.step_timeout(() => t.done(), 1000); 23 const frame = setupTest("no coep", uuid); 24 const result = await nextValueFromServer(uuid); 25 assert_unreached("embedded page should not be loaded."); 26 }, "Create fencedframe without COEP header"); 27 28 promise_test(async (t) => { 29 const uuid = token(); 30 // Make sure a different site is used. 31 hostname = get_host_info().REMOTE_HOST; 32 t.step_timeout(() => t.done(), 1000); 33 const frame = setupTest("coep:require-corp", uuid, hostname=hostname); 34 const result = await nextValueFromServer(uuid); 35 assert_unreached("embedded page should not be loaded."); 36 }, "Create fencedframe with a cross site COEP:require-corp and CORP:same-orign"); 37 </script> 38 </script> 39 </body>