summaryrefslogtreecommitdiff
path: root/cli/tests
diff options
context:
space:
mode:
Diffstat (limited to 'cli/tests')
-rw-r--r--cli/tests/error_026_remote_import_error.ts1
-rw-r--r--cli/tests/error_026_remote_import_error.ts.out7
-rw-r--r--cli/tests/import_data_url_error_stack.ts.out9
-rw-r--r--cli/tests/inline_js_source_map_2.js.out2
-rw-r--r--cli/tests/integration_tests.rs7
5 files changed, 20 insertions, 6 deletions
diff --git a/cli/tests/error_026_remote_import_error.ts b/cli/tests/error_026_remote_import_error.ts
new file mode 100644
index 000000000..1ab600cfa
--- /dev/null
+++ b/cli/tests/error_026_remote_import_error.ts
@@ -0,0 +1 @@
+import "http://localhost:4545/cli/tests/error_001.ts";
diff --git a/cli/tests/error_026_remote_import_error.ts.out b/cli/tests/error_026_remote_import_error.ts.out
new file mode 100644
index 000000000..e2d6545ef
--- /dev/null
+++ b/cli/tests/error_026_remote_import_error.ts.out
@@ -0,0 +1,7 @@
+[WILDCARD]error: Uncaught Error: bad
+ throw Error("bad");
+ ^
+ at foo (http://localhost:4545/cli/tests/error_001.ts:2:9)
+ at bar (http://localhost:4545/cli/tests/error_001.ts:6:3)
+ at http://localhost:4545/cli/tests/error_001.ts:9:1
+[WILDCARD]
diff --git a/cli/tests/import_data_url_error_stack.ts.out b/cli/tests/import_data_url_error_stack.ts.out
index ca8b906da..466c1beed 100644
--- a/cli/tests/import_data_url_error_stack.ts.out
+++ b/cli/tests/import_data_url_error_stack.ts.out
@@ -1,5 +1,6 @@
-error: Uncaught Error: Hello 2
- throw new Error(`Hello ${A.C}`);
+[WILDCARD]error: Uncaught Error: Hello 2
+ throw new Error(`Hello ${A.C}`);
^
- at a (72554b3efdc211ba4aa0b62629589f048e7d4afe7b0576f35ff340ce0ea8f9b8.ts:8:10)
- at import_data_url_error_stack.ts:3:1
+ at a (data:application/typescript;base64,ZW51bSBBIHsKICBBLAogIEIsCiAgQywKIH0KIAogZXhwb3J0IGZ1bmN0aW9uIGEoKSB7CiAgIHRocm93IG5ldyBFcnJvcihgSGVsbG8gJHtBLkN9YCk7CiB9CiA=:8:10)
+ at file:///[WILDCARD]/cli/tests/import_data_url_error_stack.ts:3:1
+[WILDCARD]
diff --git a/cli/tests/inline_js_source_map_2.js.out b/cli/tests/inline_js_source_map_2.js.out
index 008eb0657..13e50bac4 100644
--- a/cli/tests/inline_js_source_map_2.js.out
+++ b/cli/tests/inline_js_source_map_2.js.out
@@ -1,4 +1,2 @@
error: Uncaught Error: Hello world!
-throw new Error("Hello world!");
- ^
at http://localhost:4545/cli/tests/inline_js_source_map_2.ts:6:7
diff --git a/cli/tests/integration_tests.rs b/cli/tests/integration_tests.rs
index 5fa7c904f..7c0df57b7 100644
--- a/cli/tests/integration_tests.rs
+++ b/cli/tests/integration_tests.rs
@@ -3012,6 +3012,13 @@ console.log("finish");
exit_code: 1,
});
+ itest!(error_026_remote_import_error {
+ args: "run error_026_remote_import_error.ts",
+ output: "error_026_remote_import_error.ts.out",
+ exit_code: 1,
+ http_server: true,
+ });
+
itest!(error_missing_module_named_import {
args: "run --reload error_missing_module_named_import.ts",
output: "error_missing_module_named_import.ts.out",