diff options
Diffstat (limited to 'cli/tests/subdir/test_worker.ts')
-rw-r--r-- | cli/tests/subdir/test_worker.ts | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/cli/tests/subdir/test_worker.ts b/cli/tests/subdir/test_worker.ts index c8109d131..bc3f358f8 100644 --- a/cli/tests/subdir/test_worker.ts +++ b/cli/tests/subdir/test_worker.ts @@ -1,7 +1,11 @@ +if (self.name !== "tsWorker") { + throw Error(`Invalid worker name: ${self.name}, expected tsWorker`); +} + onmessage = function(e): void { console.log(e.data); postMessage(e.data); - workerClose(); + close(); }; |