| OLD | NEW |
| 1 <?php | |
| 2 // Copyright 2016 The Chromium Authors. All rights reserved. | |
| 3 // Use of this source code is governed by a BSD-style license that can be | |
| 4 // found in the LICENSE file. | |
| 5 | |
| 6 // This test ensures that navigator.vibrate when enabled for all works across | |
| 7 // origins. | |
| 8 | |
| 9 Header("Feature-Policy: {\"vibrate\": [\"*\"]}"); | |
| 10 ?> | |
| 11 | |
| 12 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 13 <html> | 2 <html> |
| 14 <head> | 3 <head> |
| 15 <script src="../../resources/testharness.js"></script> | 4 <script src="../../resources/testharness.js"></script> |
| 16 <script src="../../resources/testharnessreport.js"></script> | 5 <script src="../../resources/testharnessreport.js"></script> |
| 17 <script> | 6 <script> |
| 18 if (window.testRunner) { | 7 if (window.testRunner) { |
| 19 testRunner.dumpAsText(); | 8 testRunner.dumpAsText(); |
| 20 testRunner.dumpChildFramesAsText(); | 9 testRunner.dumpChildFramesAsText(); |
| 21 } | 10 } |
| 22 </script> | 11 </script> |
| 23 </head> | 12 </head> |
| 24 <body> | 13 <body> |
| 25 <iframe id="f1" src="resources/feature-policy-vibrate-enabled.html"></iframe> | 14 <iframe id="f1" src="resources/feature-policy-vibrate-enabled.html" allow="vibra
te"></iframe> |
| 26 <iframe id="f2" src="http://localhost:8000/feature-policy/resources/feature-poli
cy-vibrate-enabled.html"></iframe> | 15 <iframe id="f2" src="http://localhost:8000/feature-policy/resources/feature-poli
cy-vibrate-enabled.html" allow="vibrate"></iframe> |
| 27 </body> | 16 </body> |
| 28 </html> | 17 </html> |
| OLD | NEW |