diff options
author | Yoshiya Hinosawa <stibium121@gmail.com> | 2023-03-17 12:22:09 +0900 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-03-17 12:22:09 +0900 |
commit | e30d24be72cbdbadd937b1e1d7991c74829719f7 (patch) | |
tree | 935f972819988c06cd31a4b3cda3810c744bc22c /cli/tests/unit | |
parent | 8f9becee76f26db7893caabb9f3a1a7980791e0e (diff) |
chore(ext/console): add 'quotes' internal option to Deno.inspect (#18183)
Diffstat (limited to 'cli/tests/unit')
-rw-r--r-- | cli/tests/unit/console_test.ts | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/cli/tests/unit/console_test.ts b/cli/tests/unit/console_test.ts index 2b7426b99..89e9d729f 100644 --- a/cli/tests/unit/console_test.ts +++ b/cli/tests/unit/console_test.ts @@ -2155,3 +2155,16 @@ Deno.test(function inspectorMethods() { console.profile("test"); console.profileEnd("test"); }); + +Deno.test(function inspectQuotesOverride() { + assertEquals( + // @ts-ignore - 'quotes' is an internal option + Deno.inspect("foo", { quotes: ["'", '"', "`"] }), + "'foo'", + ); + assertEquals( + // @ts-ignore - 'quotes' is an internal option + Deno.inspect("'foo'", { quotes: ["'", '"', "`"] }), + `"'foo'"`, + ); +}); |