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

Unified Diff: third_party/WebKit/LayoutTests/http/tests/security/resources/same-origin-iframe-for-vibrate-allowed.html

Issue 2354433002: Block navigator.vibrate in cross-domain iframe. (Closed)
Patch Set: Change the error message to: "A call of navigator.vibrate will be no-op inside cross-origin iframes" Created 4 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/LayoutTests/http/tests/security/resources/same-origin-iframe-for-vibrate-allowed.html
diff --git a/third_party/WebKit/LayoutTests/http/tests/security/resources/referrer-attr-anchor-noreferrer-target.html b/third_party/WebKit/LayoutTests/http/tests/security/resources/same-origin-iframe-for-vibrate-allowed.html
similarity index 64%
copy from third_party/WebKit/LayoutTests/http/tests/security/resources/referrer-attr-anchor-noreferrer-target.html
copy to third_party/WebKit/LayoutTests/http/tests/security/resources/same-origin-iframe-for-vibrate-allowed.html
index fb75bd82e864ca03678ce63ab3576b466521aed8..d5b3f8f5884276bac569c963d3daa4fdbb5c6580 100644
--- a/third_party/WebKit/LayoutTests/http/tests/security/resources/referrer-attr-anchor-noreferrer-target.html
+++ b/third_party/WebKit/LayoutTests/http/tests/security/resources/same-origin-iframe-for-vibrate-allowed.html
@@ -7,8 +7,8 @@
<body>
<script>
test(function () {
- assert_equals("", document.referrer);
- }, "noreferrer link takes precedence over referrerpolicy attribute");
+ assert_true(navigator.vibrate(200));
+ }, "A same-origin iframe may call navigator.vibrate.");
</script>
</body>
</html>

Powered by Google App Engine
This is Rietveld 408576698