Cover zero-length file byte-range rejection cases

Co-authored-by: Theo Browne <[email protected]>
This commit is contained in:
Cursor AgentandTheo Browne committed 2026-02-10 02:56:57 +00:00
1 parent cf73b44095
commit 10c7207895
1 file changed
+2
+2
View File
@@ -931,6 +931,8 @@ describe("parseByteRangeHeader", () => {
expect(parseByteRangeHeader("bytes=10-9", 100)).toBe("invalid");
expect(parseByteRangeHeader("bytes=100-101", 100)).toBe("invalid");
expect(parseByteRangeHeader("bytes=-0", 100)).toBe("invalid");
expect(parseByteRangeHeader("bytes=0-0", 0)).toBe("invalid");
expect(parseByteRangeHeader("bytes=-1", 0)).toBe("invalid");
});
});