Source code
Revision control
Copy as Markdown
Other Tools
Test Info:
- This WPT test may be referenced by the following Test IDs:
- /workers/constructors/SharedWorker/undefined-arguments.html - WPT Dashboard Interop Dashboard
<!doctype html>
<title>undefined as arguments</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script>
async_test(t => {
const worker = new SharedWorker(undefined, undefined);
worker.port.onmessage = t.step_func_done(e => {
assert_equals(e.data[0], 'undefined', 'first arg (script name)');
assert_equals(e.data[1], '', 'second arg (worker name)');
});
}, 'Test constructing a shared worker with undefined');
</script>