MCPcopy Index your code
hub / github.com/nodejs/node / testEarlyExit

Function testEarlyExit

test/parallel/test-stream-iter-transform-sync.js:182–191  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

180// =============================================================================
181
182function testEarlyExit() {
183 const input = 'y'.repeat(100_000);
184 const compressed = pullSync(fromSync(input), compressGzipSync());
185
186 // eslint-disable-next-line no-unused-vars
187 for (const batch of compressed) {
188 break; // Early exit - should trigger finally block cleanup
189 }
190 // If we get here without crashing, cleanup worked
191}
192
193// =============================================================================
194// Empty input

Calls 3

pullSyncFunction · 0.85
compressGzipSyncFunction · 0.85
fromSyncFunction · 0.50

Tested by

no test coverage detected