idle-detection-allowed-by-permissions-policy-worker.js (296B)
1 'use strict'; 2 3 importScripts('/resources/testharness.js'); 4 5 let workerType; 6 7 if (typeof postMessage === 'function') { 8 workerType = 'dedicated'; 9 } 10 11 promise_test(async () => { 12 await new IdleDetector().start() 13 }, 14 `Inherited header permissions policy allows ${workerType} workers.`) 15 16 done();