Source code
Revision control
Copy as Markdown
Other Tools
Test Info:
- This WPT test may be referenced by the following Test IDs:
- /html/webappapis/dynamic-markup-insertion/opening-the-input-stream/document-open-cancels-javascript-url-navigation.html - WPT Dashboard Interop Dashboard
<body>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script>
async_test(t => {
window.onload = t.step_func_done(() => assert_equals(i.contentDocument.body.innerText, "PASS"));
var i = document.createElement('iframe');
i.id ='i';
i.src = "javascript:'FAIL'";
document.body.appendChild(i);
i.contentDocument.open();
i.contentDocument.write("PASS")
i.contentDocument.close();
});
</script>
</body>