()
| 285 | // Multiple consumers pulling concurrently should each receive all items |
| 286 | // even when only one item is pulled from source at a time. |
| 287 | async function* slowSource() { |
| 288 | const enc = new TextEncoder(); |
| 289 | for (let i = 0; i < 5; i++) { |
| 290 | await setTimeout(1); |
| 291 | yield [enc.encode(`item-${i}`)]; |
| 292 | } |
| 293 | } |
| 294 | const shared = share(slowSource()); |
| 295 | const c1 = shared.pull(); |
| 296 | const c2 = shared.pull(); |
no test coverage detected
searching dependent graphs…