Skip to content

Commit

Permalink
fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
kt3k committed Jan 10, 2025
1 parent 702074c commit a0127de
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions testing/unit/error_test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,19 @@ test(function testCustomError() {

test(function testJsErrorConstructors() {
const error = new Error("message");
const badResource = new Deno.core.BadResource("bad resource", { cause: error });
const badResource = new Deno.core.BadResource("bad resource", {
cause: error,
});
assertEquals(badResource.message, "bad resource");
assertEquals(badResource.cause, error);

const Interrupted = new Deno.core.Interrupted("interrupted", { cause: error });
const Interrupted = new Deno.core.Interrupted("interrupted", {
cause: error,
});
assertEquals(Interrupted.message, "interrupted");
assertEquals(Interrupted.cause, error);

const notCapable = new Deno.core.NotCapable("not capable", { cause: error });
assertEquals(notCapable.message, "not capable");
assertEquals(notCapable.cause, error);
})
});

0 comments on commit a0127de

Please sign in to comment.