ladybird/Tests/LibWeb/Text/input/HTML/HTMLSelectElement-can-select-option-in-JS.html
Timur Sultanov 1ce9bbdd6d Tests: Add test for selection option in <select>
Verify that we can select option using JS
2024-07-26 09:15:39 +01:00

16 lines
346 B
HTML

<!DOCTYPE html>
<script src="../include.js"></script>
<select id="select-test">
<option>A</option>
<option>B</option>
</select>
<script>
test(() => {
const s = document.getElementById("select-test");
s.options[1].selected = true;
if(s.value === "B") {
println("PASS");
}
});
</script>