summaryrefslogtreecommitdiff
path: root/cli/tests
diff options
context:
space:
mode:
Diffstat (limited to 'cli/tests')
-rw-r--r--cli/tests/integration_tests.rs6
-rw-r--r--cli/tests/js_import_detect.ts3
-rw-r--r--cli/tests/js_import_detect.ts.out1
3 files changed, 10 insertions, 0 deletions
diff --git a/cli/tests/integration_tests.rs b/cli/tests/integration_tests.rs
index 35127c155..fb35163f0 100644
--- a/cli/tests/integration_tests.rs
+++ b/cli/tests/integration_tests.rs
@@ -588,6 +588,12 @@ itest!(_054_info_local_imports {
exit_code: 0,
});
+itest!(js_import_detect {
+ args: "run --reload js_import_detect.ts",
+ output: "js_import_detect.ts.out",
+ exit_code: 0,
+});
+
itest!(lock_write_fetch {
args:
"run --allow-read --allow-write --allow-env --allow-run lock_write_fetch.ts",
diff --git a/cli/tests/js_import_detect.ts b/cli/tests/js_import_detect.ts
new file mode 100644
index 000000000..7b90dfe63
--- /dev/null
+++ b/cli/tests/js_import_detect.ts
@@ -0,0 +1,3 @@
+function define(_foo: string[]): void {}
+define(["long"]);
+console.log("ok");
diff --git a/cli/tests/js_import_detect.ts.out b/cli/tests/js_import_detect.ts.out
new file mode 100644
index 000000000..9766475a4
--- /dev/null
+++ b/cli/tests/js_import_detect.ts.out
@@ -0,0 +1 @@
+ok