From e8ee5da459f6addd15b726ff5860cfb148c2c60f Mon Sep 17 00:00:00 2001 From: Nayeem Rahman Date: Tue, 19 Oct 2021 17:26:45 +0100 Subject: fix(core/bindings): use is_instance_of_error() instead of is_native_error() (#12479) --- cli/tests/testdata/eval_context_throw_dom_exception.js | 2 ++ cli/tests/testdata/eval_context_throw_dom_exception.js.out | 1 + 2 files changed, 3 insertions(+) create mode 100644 cli/tests/testdata/eval_context_throw_dom_exception.js create mode 100644 cli/tests/testdata/eval_context_throw_dom_exception.js.out (limited to 'cli/tests/testdata') diff --git a/cli/tests/testdata/eval_context_throw_dom_exception.js b/cli/tests/testdata/eval_context_throw_dom_exception.js new file mode 100644 index 000000000..b8e99d498 --- /dev/null +++ b/cli/tests/testdata/eval_context_throw_dom_exception.js @@ -0,0 +1,2 @@ +const [, errorInfo] = Deno.core.evalContext('throw new DOMException("foo")'); +console.log(errorInfo); diff --git a/cli/tests/testdata/eval_context_throw_dom_exception.js.out b/cli/tests/testdata/eval_context_throw_dom_exception.js.out new file mode 100644 index 000000000..39e164083 --- /dev/null +++ b/cli/tests/testdata/eval_context_throw_dom_exception.js.out @@ -0,0 +1 @@ +{ thrown: DOMException: foo, isNativeError: true, isCompileError: false } -- cgit v1.2.3