Files
serenity/Tests/LibWeb/Text/input/HTML/document-close-iframe-load-event.html
Tim Ledbetter f9158f4210 LibWeb: Fire iframe load event on document close
This matches the behavior of other browsers.

(cherry picked from commit e1eeb93cc6095a47371d23db0bbf55eb30215cee)
2024-11-11 19:54:09 -05:00

16 lines
419 B
HTML

<!DOCTYPE html>
<script src="../include.js"></script>
<script>
asyncTest(done => {
const iframe = document.createElement('iframe');
document.body.appendChild(iframe);
iframe.contentDocument.open();
iframe.onload = () => {
println("Onload event fired");
iframe.remove();
done();
};
iframe.contentDocument.close();
});
</script>