no-sandboxed-automatic-features.html (569B)
1 <!DOCTYPE html> 2 <script src="/resources/testharness.js"></script> 3 <script src="/resources/testharnessreport.js"></script> 4 <script src="resources/utils.js"></script> 5 6 <iframe sandbox srcdoc="<input autofocus>"></iframe> 7 8 <script> 9 'use strict'; 10 11 promise_test(async () => { 12 await waitForLoad(window); 13 await waitUntilStableAutofocusState(); 14 assert_not_equals(document.activeElement, document.querySelector('iframe')); 15 }, 'If the sandboxed automatic features browsing context flag is set, ' + 16 'autofocus in the browsing context should not be handled.'); 17 </script>