Source code
Revision control
Copy as Markdown
Other Tools
Test Info:
- This WPT test may be referenced by the following Test IDs:
- /html/webappapis/microtask-queuing/queue-microtask-exceptions.any.html - WPT Dashboard Interop Dashboard
- /html/webappapis/microtask-queuing/queue-microtask-exceptions.any.serviceworker.html - WPT Dashboard Interop Dashboard
- /html/webappapis/microtask-queuing/queue-microtask-exceptions.any.sharedworker.html - WPT Dashboard Interop Dashboard
- /html/webappapis/microtask-queuing/queue-microtask-exceptions.any.worker.html - WPT Dashboard Interop Dashboard
// META: global=window,worker
"use strict";
setup({
allow_uncaught_exception: true
});
async_test(t => {
const error = new Error("boo");
self.addEventListener("error", t.step_func_done(ev => {
assert_equals(ev.error, error);
}));
queueMicrotask(() => { throw error; });
}, "It rethrows exceptions");