diff options
author | Nayeem Rahman <muhammed.9939@gmail.com> | 2020-03-19 23:15:21 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-03-19 19:15:21 -0400 |
commit | b7e6a31a425901c089f4b524774b985906982fae (patch) | |
tree | 44cca26406b7f270d289627c1bba0184901e50f6 /std/testing/asserts.ts | |
parent | a6d8098b35ae8580953b1f87ab3246b05a8a944e (diff) |
fix(std/http): Fix respond error test on Windows (#4408)
Diffstat (limited to 'std/testing/asserts.ts')
-rw-r--r-- | std/testing/asserts.ts | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/std/testing/asserts.ts b/std/testing/asserts.ts index 1c6dfff19..44c311204 100644 --- a/std/testing/asserts.ts +++ b/std/testing/asserts.ts @@ -348,9 +348,9 @@ export async function assertThrowsAsync( await fn(); } catch (e) { if (ErrorClass && !(Object.getPrototypeOf(e) === ErrorClass.prototype)) { - msg = `Expected error to be instance of "${ErrorClass.name}"${ - msg ? `: ${msg}` : "." - }`; + msg = `Expected error to be instance of "${ErrorClass.name}", but got "${ + e.name + }"${msg ? `: ${msg}` : "."}`; throw new AssertionError(msg); } if (msgIncludes && !e.message.includes(msgIncludes)) { |