MCPcopy Create free account
hub / github.com/nodejs/node / testPipeToSyncNoEndSync

Function testPipeToSyncNoEndSync

test/parallel/test-stream-iter-pipeto-edge.js:23–31  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

21
22// pipeToSync endSync missing → falls back to end()
23async function testPipeToSyncNoEndSync() {
24 let endCalled = false;
25 const writer = {
26 writeSync() { return true; },
27 end() { endCalled = true; },
28 };
29 pipeToSync(fromSync('data'), writer);
30 assert.strictEqual(endCalled, true);
31}
32
33// pipeToSync with preventFail: true — source error does NOT call fail()
34async function testPipeToSyncPreventFail() {

Callers 1

Calls 2

pipeToSyncFunction · 0.85
fromSyncFunction · 0.50

Tested by

no test coverage detected