(promise, destination, pipeFailureSignal)
| 38 | The return value of `.pipe()` exposes the destination subprocess' output, but its iteration and stream conversion methods must await the whole pipe so source failures are propagated too. The destination is `undefined` when `.pipe()` was passed invalid arguments, in which case the promise rejects and there is nothing to forward. |
| 39 | */ |
| 40 | const forwardDestinationMethods = (promise, destination, pipeFailureSignal) => { |
| 41 | if (destination === undefined) { |
| 42 | return; |
| 43 | } |
| 44 | |
| 45 | forwardReadableMethods(promise, destination); |
| 46 | forwardIpcMethods(promise, destination, pipeFailureSignal); |
| 47 | }; |
| 48 | |
| 49 | const forwardReadableMethods = (promise, destination) => { |
| 50 | const subprocessOptions = SUBPROCESS_OPTIONS.get(destination); |
no test coverage detected