cross-document-nav-stop.html (699B)
1 <!DOCTYPE html> 2 <meta charset="utf-8"> 3 <title>Stop during cross-document navigations</title> 4 <script src="/resources/testharness.js"></script> 5 <script src="/resources/testharnessreport.js"></script> 6 7 <body> 8 <script type="module"> 9 import { createIframe, waitForPotentialNetworkLoads } from "./resources/helpers.mjs"; 10 11 promise_test(async t => { 12 const iframe = await createIframe(t); 13 14 iframe.contentWindow.location.search = "?1"; 15 iframe.contentWindow.onload = t.unreached_func("load event fired"); 16 iframe.contentWindow.stop(); 17 18 await waitForPotentialNetworkLoads(t); 19 assert_equals(iframe.contentWindow.location.search, ""); 20 }, "cross-document navigations are stopped by stop()"); 21 </script>