Files
ladybird/Tests/LibWeb/Text/input/video-gc.html
Timothy Flynn 512cea5a87 LibWeb: Bring back the test video for LibWeb tests
The video was accidentally removed in commit d5ba665f89.

This adds the video back to the LibWeb/Text/data folder, and validates
that the video loads in the test that depends on it loading.
2024-10-10 17:52:58 -04:00

28 lines
648 B
HTML

<iframe id="iframe"></iframe>
<script src="include.js"></script>
<script>
function navigateIframe(src) {
return new Promise(resolve => {
window.onmessage = e => {
println(e.data);
resolve();
};
iframe.src = src;
});
}
asyncTest(async done => {
await navigateIframe("../data/video-gc-frame.html");
await navigateIframe("../data/iframe-test-content-1.html");
iframe.remove();
for (let i = 0; i < 5; ++i) {
internals.gc();
}
println("PASS (didn't crash)");
done();
});
</script>