Skip to content

Commit 0c47d31

Browse files
committed
Improve code coverage
1 parent 6477fcd commit 0c47d31

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

library/sinks/Fetch.test.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,16 @@ t.test(
164164
"Zen has blocked a server-side request forgery: fetch(...) originating from body.image"
165165
);
166166
}
167+
168+
const error4 = await t.rejects(() =>
169+
fetch(new Request("http://localhost:4000/api/internal"))
170+
);
171+
if (error4 instanceof Error) {
172+
t.same(
173+
error4.message,
174+
"Zen has blocked a server-side request forgery: fetch(...) originating from body.image"
175+
);
176+
}
167177
});
168178

169179
await runWithContext(

0 commit comments

Comments
 (0)