summaryrefslogtreecommitdiff
path: root/cli/tests/fix_dynamic_import_errors.js
diff options
context:
space:
mode:
authorKitson Kelly <me@kitsonkelly.com>2020-12-15 16:52:55 +1100
committerGitHub <noreply@github.com>2020-12-15 16:52:55 +1100
commit63a821b78b5a293c0eb5b3ecc18d67bde8331eda (patch)
tree4229af0ba8b9f56467f1355b0c53054b69039edf /cli/tests/fix_dynamic_import_errors.js
parentb6d5ae1ecd125ce8a14cddc877cb66dbcfc9bb04 (diff)
fix(cli): make dynamic import errors catchable (#8750)
Fixes #6259
Diffstat (limited to 'cli/tests/fix_dynamic_import_errors.js')
-rw-r--r--cli/tests/fix_dynamic_import_errors.js7
1 files changed, 7 insertions, 0 deletions
diff --git a/cli/tests/fix_dynamic_import_errors.js b/cli/tests/fix_dynamic_import_errors.js
new file mode 100644
index 000000000..317047ccb
--- /dev/null
+++ b/cli/tests/fix_dynamic_import_errors.js
@@ -0,0 +1,7 @@
+import("./dynamic_import/b.js").catch(() => {
+ console.log("caught import error from b.js");
+});
+
+import("./dynamic_import/c.js").catch(() => {
+ console.log("caught import error from c.js");
+});