Chromium Code Reviews| Index: third_party/WebKit/LayoutTests/http/tests/feature-policy/fullscreen-enabledforself.php |
| diff --git a/third_party/WebKit/LayoutTests/http/tests/feature-policy/fullscreen-enabledforself.php b/third_party/WebKit/LayoutTests/http/tests/feature-policy/fullscreen-enabledforself.php |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..c19bd245c3134968d20ccfa549eefcb22b01f65b |
| --- /dev/null |
| +++ b/third_party/WebKit/LayoutTests/http/tests/feature-policy/fullscreen-enabledforself.php |
| @@ -0,0 +1,31 @@ |
| +<?php |
| +// Copyright 2016 The Chromium Authors. All rights reserved. |
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +// This test ensures that fullscreen feature when enabled for self only works |
| +// in the same orgin but not cross origins when allowfullscreen is set. No |
| +// iframe may call it when allowfullscreen is not set. |
| + |
| +Header("Feature-Policy: {\"fullscreen\": [\"self\"]}"); |
| +?> |
| + |
| +<!DOCTYPE html> |
| +<html> |
| +<head> |
| +<script src="../../resources/testharness.js"></script> |
| +<script src="../../resources/testharnessreport.js"></script> |
| +<script> |
| + if (window.testRunner) { |
| + testRunner.dumpAsText(); |
| + testRunner.dumpChildFramesAsText(); |
|
foolip
2016/11/29 16:06:36
It turns out that this is the magic I couldn't und
lunalu1
2016/12/01 20:10:07
Done.
|
| + } |
| +</script> |
| +</head> |
| +<body> |
| +<iframe id="f1" src="resources/feature-policy-fullscreen-enabled.html" allowfullscreen></iframe> |
| +<iframe id="f2" src="http://localhost:8000/feature-policy/resources/feature-policy-fullscreen-disabled.html" allowfullscreen></iframe> |
| +<iframe id="f3" src="resources/feature-policy-vibrate-enabled.html"></iframe> |
|
foolip
2016/11/29 16:06:36
typo here, shouldn't be testing vibrate
lunalu1
2016/12/01 20:10:07
Done.
|
| +<iframe id="f4" src="http://localhost:8000/feature-policy/resources/feature-policy-fullscreen-disabled.html"></iframe> |
| +</body> |
| +</html> |