()
| 59 | } |
| 60 | |
| 61 | async function testWriterFail() { |
| 62 | const { writer, readable } = push(); |
| 63 | |
| 64 | writer.fail(new Error('test fail')); |
| 65 | |
| 66 | await assert.rejects( |
| 67 | async () => { |
| 68 | // eslint-disable-next-line no-unused-vars |
| 69 | for await (const _ of readable) { |
| 70 | assert.fail('Should not reach here'); |
| 71 | } |
| 72 | }, |
| 73 | { message: 'test fail' }, |
| 74 | ); |
| 75 | } |
| 76 | |
| 77 | async function testConsumerBreak() { |
| 78 | const { writer, readable } = push({ highWaterMark: 10 }); |
no test coverage detected