gamepad.https.html (629B)
1 <!DOCTYPE html> 2 <title>Gamepad API test</title> 3 <script src="/resources/testharness.js"></script> 4 <script src="/resources/testharnessreport.js"></script> 5 <script src="/common/utils.js"></script> 6 <script src="resources/utils.js"></script> 7 8 <body> 9 <script> 10 promise_test(async () => { 11 const key = token(); 12 attachFencedFrame(generateURL('resources/gamepad-inner.html', [key])); 13 const result = await nextValueFromServer(key); 14 assert_equals( 15 result, 16 'SecurityError', 17 'getGamepads should throw an error in a fenced frame'); 18 }, 'Gamepads information should not be read in the fenced frame.'); 19 </script> 20 </body>