blob: 7155c94eac0e9c756b4ce8790925f1d9b6809ade [file] [log] [blame] [edit]
// META: title=Scheduler: postTask Error Propagation
// META: global=window,worker
'use strict';
promise_test(t => {
const testError = new Error('Failed');
const task = scheduler.postTask(() => { throw testError; });
return promise_rejects_exactly(t, testError, task, 'postTask should propagate the error');
}, 'Test postTask rejects the associated promise with the callback error');