ladybird/Tests/LibWeb/Text/input/DOM/DOMStringMap-setter-with-invalid-name.html
Andreas Kling 093f1dd805 LibWeb: Propagate exceptions from setAttribute() in DOMStringMap setter
We were incorrectly assuming that setAttribute() could never fail here,
even when passed an invalid name.

Found by Domato.
2024-07-20 06:41:25 +02:00

12 lines
314 B
HTML

<script src="../include.js"></script>
<script>
test(() => {
let threw = false;
try {
document.body.dataset["'\uDBF8"] = "foo";
} catch {
threw = true;
}
println("Setting DOMStringMap with an invalid name key throws? " + threw);
});
</script>