diff options
Diffstat (limited to 'cli')
-rw-r--r-- | cli/tests/integration/run_tests.rs | 7 | ||||
-rw-r--r-- | cli/tests/testdata/classic_workers_event_loop.js | 4 | ||||
-rw-r--r-- | cli/tests/testdata/classic_workers_event_loop.js.out | 1 |
3 files changed, 12 insertions, 0 deletions
diff --git a/cli/tests/integration/run_tests.rs b/cli/tests/integration/run_tests.rs index c7e0325ec..981b85199 100644 --- a/cli/tests/integration/run_tests.rs +++ b/cli/tests/integration/run_tests.rs @@ -1109,6 +1109,13 @@ itest!(import_file_with_colon { output: "import_file_with_colon.ts.out", http_server: true, }); + +itest!(classic_workers_event_loop { + args: + "run --enable-testing-features-do-not-use classic_workers_event_loop.js", + output: "classic_workers_event_loop.js.out", +}); + // FIXME(bartlomieju): disabled, because this test is very flaky on CI // itest!(local_sources_not_cached_in_memory { // args: "run --allow-read --allow-write no_mem_cache.js", diff --git a/cli/tests/testdata/classic_workers_event_loop.js b/cli/tests/testdata/classic_workers_event_loop.js new file mode 100644 index 000000000..810a6df7f --- /dev/null +++ b/cli/tests/testdata/classic_workers_event_loop.js @@ -0,0 +1,4 @@ +new Worker( + "data:application/javascript,setTimeout(() => {console.log('done'); self.close()}, 1000)", + { type: "classic" }, +); diff --git a/cli/tests/testdata/classic_workers_event_loop.js.out b/cli/tests/testdata/classic_workers_event_loop.js.out new file mode 100644 index 000000000..19f86f493 --- /dev/null +++ b/cli/tests/testdata/classic_workers_event_loop.js.out @@ -0,0 +1 @@ +done |