Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(232)

Side by Side Diff: third_party/WebKit/LayoutTests/external/wpt/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_allow_top_navigation_by_user_activation-manual.html

Issue 2713283002: Turn on the flag for 'allow-top-navigation-by-user-activation'. (Closed)
Patch Set: Refine the error message for blocked navigation within sandboxed iframe. Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 <html> 1 <html>
2 <head> 2 <head>
3 <style> 3 <style>
4 iframe { width: 400px; height: 200px;} 4 iframe { width: 400px; height: 300px;}
5 </style> 5 </style>
6 <script src="/resources/testharness.js"></script> 6 <script src="/resources/testharness.js"></script>
7 <script src="/resources/testharnessreport.js"></script> 7 <script src="/resources/testharnessreport.js"></script>
8 <script> 8 <script>
9 setup({explicit_timeout: true}); 9 setup({explicit_timeout: true});
10 10
11 async_test(function(t) { 11 async_test(function(t) {
12 window.addEventListener("message", t.step_func_done(function(e) { 12 window.addEventListener("message", t.step_func_done(function(e) {
13 assert_equals(e.data, "BLOCKED", "The message should say 'BLOCKED'." ); 13 assert_equals(e.data, "BLOCKED", "The message should say 'BLOCKED'." );
14 })); 14 }));
15 }, "The sandboxed iframe should post a message saying the top navigation w as blocked when no user gesture."); 15 }, "The sandboxed iframe should post a message saying the top navigation w as blocked when no user gesture.");
16 </script> 16 </script>
17 </head> 17 </head>
18 <body> 18 <body>
19 <p>This tests that an iframe in sandbox with 'allow-top-navigation-by-user-a ctivation' 19 <p>This tests that an iframe in sandbox with 'allow-top-navigation-by-user-a ctivation'
20 can navigate the top level page, if it is trigged by a user gesture.</p> 20 can navigate the top level page, if it is trigged by a user gesture.</p>
21 <p>Click on the button in the iframe and it should navigate the top page.</p > 21 <p>Click on the button in the iframe and it should navigate the top page.</p >
22 <iframe id="i" sandbox="allow-scripts allow-top-navigation-by-user-activatio n" src="support/iframe-that-performs-top-navigation.html"></iframe> 22 <iframe id="i" sandbox="allow-scripts allow-top-navigation-by-user-activatio n" src="support/iframe-that-performs-top-navigation.html"></iframe>
23 </body> 23 </body>
24 </html> 24 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698