WorkerGlobalScope_EventTarget.htm
<!DOCTYPE html>
<title> WorkerGlobalScope implements EventTarget </title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<div id=log></div>
<script>
async_test(function(t) {
var worker = new Worker('./support/EventListener.js');
worker.onmessage = t.step_func_done(function(e) {
var global = e.data[0];
var target = e.data[1];
assert_regexp_match(target, /\[object (.*?)Worker(.+?)\]/);
assert_equals(target, global);
});
worker.postMessage("TestEventTarget");
});
</script>