Skip to content

Commit

Permalink
test(public): add failing test case
Browse files Browse the repository at this point in the history
  • Loading branch information
SukkaW committed Aug 18, 2022
1 parent f7eed07 commit 06efbf4
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
Binary file not shown.
7 changes: 7 additions & 0 deletions test/integration/file-serving/test/index.test.js
Expand Up @@ -61,6 +61,13 @@ const runTests = () => {
expect(await res.text()).toBe('hi')
})

it('should serve avif image with correct content-type', async () => {
// vercel-icon-dark.avif is downloaded from https://vercel.com/design and transformed to avif on avif.io
const res = await fetchViaHTTP(appPort, '/vercel-icon-dark.avif')
expect(res.status).toBe(200)
expect(res.headers.get('content-type')).toBe('image/avif')
})

// checks against traversal requests from
// https://github.com/swisskyrepo/PayloadsAllTheThings/blob/master/Directory%20Traversal/Intruder/traversals-8-deep-exotic-encoding.txt

Expand Down

0 comments on commit 06efbf4

Please sign in to comment.