Skip to content

Commit

Permalink
Improve code coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
timokoessler committed Jan 20, 2025
1 parent 6477fcd commit 0c47d31
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions library/sinks/Fetch.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,16 @@ t.test(
"Zen has blocked a server-side request forgery: fetch(...) originating from body.image"
);
}

const error4 = await t.rejects(() =>
fetch(new Request("http://localhost:4000/api/internal"))
);
if (error4 instanceof Error) {
t.same(
error4.message,
"Zen has blocked a server-side request forgery: fetch(...) originating from body.image"
);
}
});

await runWithContext(
Expand Down

0 comments on commit 0c47d31

Please sign in to comment.