Closed Bug 1452117 Opened 5 years ago Closed 5 years ago

[wpt-sync] Sync PR 6618 - Verify that modals are blocked in sandboxed frames without 'allow-mod…


(Core :: DOM: Core & HTML, enhancement, P4)




Tracking Status
firefox61 --- fixed


(Reporter:, Unassigned)




(Whiteboard: [wptsync downstream])

Sync web-platform-tests PR 6618 into mozilla-central (this bug is closed when the sync is complete).

Details from upstream follow.

Frédéric Wang <> wrote:
>  Verify that modals are blocked in sandboxed frames without 'allow-mod…
>  …als'.
>  Writing tests for allow-modals seem a bit complicated because the modals dialog blocks the UI. I made various attempts with popups and so on, but that does not work consistently on the various web engines. I have not tried it, but I'm not sure how is supposed to work as it has similar assertions as sandbox-iframe-blocks-modals.php
>  So for now I'm only adding tests to verify that modal dialogs return immediately when they are blocked. To handle the case where the browser incorrectly allow one of these dialogs, I used separate files and added some provision to ensure test failure.
>  Gecko seems to return a boolean for window.print contrary to what the spec says.
Component: web-platform-tests → DOM
Product: Testing → Core
Ran 4 tests and 4 subtests
OK     : 3
PASS   : 3

New tests that have failures or other problems:
/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_block_modals-4.html: TIMEOUT
    Frames without `allow-modals` should not be able to open modal dialogs: TIMEOUT
Pushed by
[wpt PR 6618] - Verify that modals are blocked in sandboxed frames without 'allow-mod…, a=testonly
[wpt PR 6618] - Update wpt metadata, a=testonly
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.