OLD | NEW |
(Empty) | |
| 1 <!DOCTYPE html> |
| 2 <body> |
| 3 <script src=/resources/testharness.js></script> |
| 4 <script src=/resources/testharnessreport.js></script> |
| 5 <script src=resources/featurepolicytest.js></script> |
| 6 <script> |
| 7 'use strict'; |
| 8 |
| 9 promise_test( |
| 10 () => navigator.usb.getDevices(), |
| 11 'Feature-Policy header {"usb": ["*"]} allows the top-level document.'); |
| 12 |
| 13 async_test(t => { |
| 14 assert_usb_available_in_iframe(t, '', '#OK'); |
| 15 }, 'Feature-Policy header {"usb": ["*"]} allows same-origin iframes.'); |
| 16 |
| 17 async_test(t => { |
| 18 assert_usb_available_in_iframe(t, 'https://{{domains[www]}}:{{ports[https][0]}
}', '#OK'); |
| 19 }, 'Feature-Policy header {"usb": ["*"]} allows cross-origin iframes.'); |
| 20 </script> |
| 21 </body> |
OLD | NEW |