summaryrefslogtreecommitdiff
path: root/cli/tests
diff options
context:
space:
mode:
authorTim Ermilov <yamalight@gmail.com>2020-01-31 22:07:37 +0100
committerGitHub <noreply@github.com>2020-01-31 16:07:37 -0500
commit2cd3994902fb6a4d4d0603c839a78503d792b96a (patch)
treee2b16efc22a09ae7020804d794484df4b967e291 /cli/tests
parent1dc8afe3afc483703641c907075e2d8aa7396cfd (diff)
Add support for multiple files in fetch command (#3845)
Diffstat (limited to 'cli/tests')
-rw-r--r--cli/tests/037_fetch_multiple.out5
-rw-r--r--cli/tests/fetch/other.ts1
-rw-r--r--cli/tests/fetch/test.ts1
-rw-r--r--cli/tests/integration_tests.rs7
4 files changed, 14 insertions, 0 deletions
diff --git a/cli/tests/037_fetch_multiple.out b/cli/tests/037_fetch_multiple.out
new file mode 100644
index 000000000..cdb6fe2ba
--- /dev/null
+++ b/cli/tests/037_fetch_multiple.out
@@ -0,0 +1,5 @@
+Compile [WILDCARD]/fetch/test.ts
+Download http://localhost:4545/cli/tests/subdir/mod2.ts
+Download http://localhost:4545/cli/tests/subdir/print_hello.ts
+Compile [WILDCARD]/fetch/other.ts
+Download http://localhost:4545/cli/tests/subdir/mt_text_typescript.t1.ts
diff --git a/cli/tests/fetch/other.ts b/cli/tests/fetch/other.ts
new file mode 100644
index 000000000..ab85b226f
--- /dev/null
+++ b/cli/tests/fetch/other.ts
@@ -0,0 +1 @@
+import "http://localhost:4545/cli/tests/subdir/mt_text_typescript.t1.ts";
diff --git a/cli/tests/fetch/test.ts b/cli/tests/fetch/test.ts
new file mode 100644
index 000000000..1b49a76c8
--- /dev/null
+++ b/cli/tests/fetch/test.ts
@@ -0,0 +1 @@
+import "http://localhost:4545/cli/tests/subdir/mod2.ts";
diff --git a/cli/tests/integration_tests.rs b/cli/tests/integration_tests.rs
index fef69ad9e..b7dfc4e35 100644
--- a/cli/tests/integration_tests.rs
+++ b/cli/tests/integration_tests.rs
@@ -413,6 +413,13 @@ itest!(_036_import_map_fetch {
output: "036_import_map_fetch.out",
});
+itest!(_037_fetch_multiple {
+ args: "fetch --reload fetch/test.ts fetch/other.ts",
+ check_stderr: true,
+ http_server: true,
+ output: "037_fetch_multiple.out",
+});
+
itest!(_038_checkjs {
// checking if JS file is run through TS compiler
args: "run --reload --config 038_checkjs.tsconfig.json 038_checkjs.js",