diff options
author | David Sherret <dsherret@users.noreply.github.com> | 2021-07-08 09:43:36 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-07-08 09:43:36 -0400 |
commit | 5fa58c92165e23386b8ed3c3079103997fe1bef9 (patch) | |
tree | d7efc34a11322d10f2749b5083cd84fa1b4a18d6 /cli/tests/unit/response_test.ts | |
parent | 5e092b19fe113bdecd36b4e0184c82f4b3343bca (diff) |
fix: inspecting prototypes of built-ins with custom inspect implementations should not throw (#11308)
Diffstat (limited to 'cli/tests/unit/response_test.ts')
-rw-r--r-- | cli/tests/unit/response_test.ts | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/cli/tests/unit/response_test.ts b/cli/tests/unit/response_test.ts index 7e444fd83..1faf8991a 100644 --- a/cli/tests/unit/response_test.ts +++ b/cli/tests/unit/response_test.ts @@ -1,5 +1,10 @@ // Copyright 2018-2021 the Deno authors. All rights reserved. MIT license. -import { assert, assertEquals, unitTest } from "./test_util.ts"; +import { + assert, + assertEquals, + assertStringIncludes, + unitTest, +} from "./test_util.ts"; unitTest(async function responseText() { const response = new Response("hello world"); @@ -67,4 +72,5 @@ unitTest(function customInspectFunction(): void { url: "" }`, ); + assertStringIncludes(Deno.inspect(Response.prototype), "Response"); }); |