blob: 33d77e058b82fc32c7c2d8d1fbb429a1f47e0029 [file] [log] [blame]
<!doctype html>
<meta charset=utf-8>
<title>Dedicated Worker: Error event error message</title>
<script src='../../../resources/testharness.js'></script>
<script src='../../../resources/testharnessreport.js'></script>
<script>
// TODO(yiyix): This test will be superseded by
// external/wpt/workers/Worker_ErrorEvent_error.htm once
// https://crbug.com/708857 is fixed.
promise_test(t => {
return new Promise(resolve => {
var worker = new Worker('resources/error-script.js');
worker.onmessage = resolve;
})
.then(e => assert_equals(e.data.value, 'testError'));
}, 'Error handlers inside a worker should see the error value');
</script>