Skip to content

Commit

Permalink
..
Browse files Browse the repository at this point in the history
  • Loading branch information
ardatan committed Jan 24, 2025
1 parent bf76ab6 commit ab82e44
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions packages/node-fetch/tests/non-http-fetch.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,10 @@ describe('File protocol', () => {
);
expect(response.status).toBe(404);
});
it('returns 403 if file is not accessible', async () => {
const response = await fetchPonyfill(pathToFileURL('/etc/shadow'));
expect(response.status).toBe(403);

Check failure on line 24 in packages/node-fetch/tests/non-http-fetch.spec.ts

View workflow job for this annotation

GitHub Actions / unit / bun

error: expect(received).toBe(expected)

Expected: 403 Received: 200 at <anonymous> (/home/runner/work/whatwg-node/whatwg-node/packages/node-fetch/tests/non-http-fetch.spec.ts:24:29)
});
});

describe('data uris', () => {
Expand Down

0 comments on commit ab82e44

Please sign in to comment.