(length: number)
| 78 | afterAll(() => Promise.all(disposers.map((dispose) => dispose()))) |
| 79 | |
| 80 | const randomBytes = (length: number): Uint8Array => { |
| 81 | const data = new Uint8Array(length) |
| 82 | let state = 0x9e3779b9 |
| 83 | for (let i = 0; i < length; i++) { |
| 84 | state ^= state << 13 |
| 85 | state ^= state >>> 17 |
| 86 | state ^= state << 5 |
| 87 | data[i] = state & 0xff |
| 88 | } |
| 89 | return data |
| 90 | } |
| 91 | |
| 92 | describe("HttpCompression", () => { |
| 93 | it("compresses a compressible response with gzip", async () => { |
no outgoing calls
no test coverage detected