3 <p>This test checks that the invalid context doesn't cause crashes.
</p>
4 <script src=
"resources/worker-util.js"></script>
7 if (window
.testRunner
) {
8 testRunner
.dumpAsText();
9 testRunner
.setCanOpenWindows();
10 testRunner
.waitUntilDone();
13 var callbackCount
= 0;
17 if (callbackCount
== 10) {
22 // After "p.Worker = w.Worker;" is called, Worker::create() may be called with an invalid context.
23 var a
= new Worker('a');
25 var p
= window
.parent
;
26 var w
= window
.open("x", "y");
28 setTimeout(callback
, 1);
31 setTimeout(callback
, 1);