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

Side by Side Diff: third_party/WebKit/LayoutTests/http/tests/security/frameNavigation/sandbox-DENIED-top-navigation-without-user-gesture.html

Issue 2711073002: WPT tests of allow-top-navigation-by-user-activation for iframe@sandbox. (Closed)
Patch Set: Add an async_test for the manual test to test the top-navigation blocking given no user gesture. 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
(Empty)
1 <!doctype html>
2 <html>
3 <head>
4 <script src="/resources/testharness.js"></script>
5 <script src="/resources/testharnessreport.js"></script>
6 <script>
7 async_test(function(t) {
8 window.addEventListener("message", t.step_func_done(function(e) {
9 assert_equals(e.data, "PASS", "The message should say 'PASS' instead of 'F AIL'");
10 }));
11 }, "The sandboxed iframe should post a message saying the test was in the state of 'PASS'.");
12 </script>
13 </head>
14 <body>
15 <p>This tests that an iframe in sandbox with 'allow-top-navigation-by-user-a ctivation'
16 cannot navigate its top level page, if it is not trigged by a user gesture.< /p>
17 <iframe sandbox='allow-top-navigation-by-user-activation allow-scripts' src= "resources/iframe-that-performs-top-navigation-without-user-gesture-failed.html" ></iframe>
18 </body>
19 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698