mirror of
https://github.com/servo/servo.git
synced 2025-08-06 22:15:33 +01:00
Update web-platform-tests to revision 1829a42c93e435937db68c8a842fa9b56dd39dc2
This commit is contained in:
parent
9f142b9c22
commit
46e1e26950
72 changed files with 1286 additions and 1091 deletions
|
@ -0,0 +1,24 @@
|
|||
<!doctype html>
|
||||
<title>dialog element: removing from document after showModal()</title>
|
||||
<link rel=help href="https://html.spec.whatwg.org/multipage/interactive-elements.html#dom-dialog-showmodal">
|
||||
<link rel=help href="https://fullscreen.spec.whatwg.org/#removing-steps">
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<dialog></dialog>
|
||||
<script>
|
||||
async_test(t => {
|
||||
const dialog = document.querySelector('dialog')
|
||||
dialog.showModal()
|
||||
assert_true(dialog.open)
|
||||
// The dialog element is now in top layer. Removing it should synchronously
|
||||
// remove it from top layer, but should leave it in a strange limbo state.
|
||||
dialog.addEventListener('close', t.unreached_func('close event'))
|
||||
dialog.remove()
|
||||
assert_true(dialog.open)
|
||||
// if an event was queued, it would fire before this timeout
|
||||
step_timeout(t.step_func_done(() => {
|
||||
assert_true(dialog.open)
|
||||
// pass if no close event was fired
|
||||
}))
|
||||
})
|
||||
</script>
|
Loading…
Add table
Add a link
Reference in a new issue