Chromium Code Reviews

Side by Side Diff: third_party/WebKit/LayoutTests/http/tests/security/sandbox-iframe-allows-modals.html

Issue 1835463002: Stop supporting invalid CSP directives in meta tags (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: remove service worker extendable event test Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff |
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <html>
3 <head>
4 <meta http-equiv="Content-Security-Policy" content="sandbox allow-scripts al low-modals">
5 <script src="/resources/testharness.js"></script>
6 <script src="/resources/testharnessreport.js"></script>
7 </head>
8 <body>
9 <script>
10 test(function () {
11 var result = alert("Yay!");
12 assert_equals(result, undefined);
13 }, "alert() returns synchronously in a sandboxed page without blocking o n user input.");
14
15 test(function () {
16 var result = print();
17 assert_equals(result, undefined);
18 }, "print() returns synchronously in a sandboxed page without blocking o n user input.");
19
20 test(function () {
21 var result = confirm("Question?");
22 assert_equals(result, true);
23 }, "confirm() returns 'true' in a sandboxed page (in our test environmen t).");
24
25 test(function () {
26 var result = prompt("Question?");
27 assert_equals(result, null);
28 }, "prompt() returns 'null' synchronously in a sandboxed page without bl ocking on user input.");
29 </script>
30 </body>
31 </html>
OLDNEW

Powered by Google App Engine