added 'bad range' test

Massimo Melina committed Jan 23, 2022 at 15:19 UTC 5c1249bc0e679ce3bc765f6d8bf306c5b24fd041
1 file changed +3
tests/test.ts
+3
@@ -24,6 +24,9 @@ describe('basics', () => {
24 it('partial download', req('/f1/f2/alfa.txt', s => s.includes('a') && !s.includes('d'), {
25 headers: { Range: 'bytes=0-2' }
26 }))
27 + it('bad range', req('/f1/f2/alfa.txt', 416, {
28 + headers: { Range: 'bytes=7-' }
29 + }))
30 it('website', req('/f1/page/', s => s.includes('This is a test')))
31 it('missing perm', req('/for-admins/', 404))
32 it('zip+head', req('/f1/?get=zip',