Truly independent web browser
<!DOCTYPE html>
<html class="reftest-wait">
<link rel="match" href="../../expected/svg/green-square-100-ref.html">
<svg width="100" height="100">
<defs>
<pattern id="tile" width="100" height="100" patternUnits="userSpaceOnUse">
<image id="tile-image" width="100" height="100" />
</pattern>
</defs>
<rect width="100" height="100" fill="url(#tile)" />
<rect id="second" x="0" width="100" height="100" fill="url(#tile)" />
</svg>
<script>
const tileImage = document.getElementById("tile-image");
const finish = () => {
requestAnimationFrame(() => {
requestAnimationFrame(() => {
if (window.internals)
internals.signalTestIsDone("PASS");
else
document.documentElement.classList.remove("reftest-wait");
});
});
};
requestAnimationFrame(() => {
requestAnimationFrame(() => {
document.getElementById("second").remove();
requestAnimationFrame(() => {
requestAnimationFrame(() => {
tileImage.addEventListener("load", finish);
tileImage.setAttribute("href", "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAQAAAAECAIAAAAmkwkpAAAAD0lEQVR4nGNgaGBAIOI4ANA0CAF5jtVRAAAAAElFTkSuQmCC");
});
});
});
});
</script>
</html>