

    iframe.src = "resources/frameset-using-page.html";
    iframe.onload = () => {
      resolve(iframe.contentDocument.querySelector("frame"));
    };
    iframe.onerror = () => reject(new Error("Could not load frameset page"));

    document.body.append(iframe);
  });
}
</script>
