()
| 124 | // ============================================================================= |
| 125 | |
| 126 | async function testEmptyBatchAsync() { |
| 127 | async function* gen() { |
| 128 | yield []; |
| 129 | yield [Buffer.from('real data')]; |
| 130 | yield []; |
| 131 | } |
| 132 | |
| 133 | const readable = toReadable(gen()); |
| 134 | const result = await collect(readable); |
| 135 | assert.strictEqual(result.toString(), 'real data'); |
| 136 | } |
| 137 | |
| 138 | // ============================================================================= |
| 139 | // fromStreamIter: destroy mid-stream cleans up iterator |
no test coverage detected