()
| 5 | export { test }; |
| 6 | |
| 7 | async function test() { |
| 8 | zip.configure({ chunkSize: 128, useWebWorkers: true }); |
| 9 | const readable = (await fetch(new URL("../data/lorem-invalid-uncompressed-size.zip", import.meta.url))).body; |
| 10 | const zipReader = new zip.ZipReader(readable); |
| 11 | const entries = await zipReader.getEntries(); |
| 12 | try { |
| 13 | await entries[0].arrayBuffer(); |
| 14 | throw new Error(); |
| 15 | } catch (error) { |
| 16 | if (error.message != zip.ERR_INVALID_UNCOMPRESSED_SIZE) { |
| 17 | throw error; |
| 18 | } |
| 19 | await zipReader.close(); |
| 20 | } finally { |
| 21 | await zip.terminateWorkers(); |
| 22 | } |
| 23 | } |
nothing calls this directly
no test coverage detected
searching dependent graphs…