summaryrefslogtreecommitdiff
path: root/tests/testdata/run/014_duplicate_import.ts
diff options
context:
space:
mode:
Diffstat (limited to 'tests/testdata/run/014_duplicate_import.ts')
-rw-r--r--tests/testdata/run/014_duplicate_import.ts9
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/testdata/run/014_duplicate_import.ts b/tests/testdata/run/014_duplicate_import.ts
new file mode 100644
index 000000000..c7dd881cf
--- /dev/null
+++ b/tests/testdata/run/014_duplicate_import.ts
@@ -0,0 +1,9 @@
+// with all the imports of the same module, the module should only be
+// instantiated once
+import "../subdir/auto_print_hello.ts";
+
+import "../subdir/auto_print_hello.ts";
+
+(async () => {
+ await import("../subdir/auto_print_hello.ts");
+})();