summaryrefslogtreecommitdiff
path: root/tests/unit_node/testdata/worker_module
diff options
context:
space:
mode:
Diffstat (limited to 'tests/unit_node/testdata/worker_module')
-rw-r--r--tests/unit_node/testdata/worker_module/index.js3
-rw-r--r--tests/unit_node/testdata/worker_module/other_file.js3
-rw-r--r--tests/unit_node/testdata/worker_module/package.json4
3 files changed, 10 insertions, 0 deletions
diff --git a/tests/unit_node/testdata/worker_module/index.js b/tests/unit_node/testdata/worker_module/index.js
new file mode 100644
index 000000000..a3e976b65
--- /dev/null
+++ b/tests/unit_node/testdata/worker_module/index.js
@@ -0,0 +1,3 @@
+import { myFunction } from "./other_file.js";
+
+myFunction().then(() => {});
diff --git a/tests/unit_node/testdata/worker_module/other_file.js b/tests/unit_node/testdata/worker_module/other_file.js
new file mode 100644
index 000000000..41789dfe8
--- /dev/null
+++ b/tests/unit_node/testdata/worker_module/other_file.js
@@ -0,0 +1,3 @@
+export async function myFunction() {
+ await new Promise((resolve) => setTimeout(resolve, 100));
+}
diff --git a/tests/unit_node/testdata/worker_module/package.json b/tests/unit_node/testdata/worker_module/package.json
new file mode 100644
index 000000000..486d2f82b
--- /dev/null
+++ b/tests/unit_node/testdata/worker_module/package.json
@@ -0,0 +1,4 @@
+{
+ "name": "foo",
+ "type": "module"
+}