@@ -171,7 +171,12 @@ class HookTransform extends Transform {
171171 }
172172}
173173
174- Readable . from ( [ source ( "transform-hook" ) ] ) . pipe ( new HookTransform ( ) ) ;
174+ Readable . from ( [ source ( "transform-hook" ) ] ) . pipe ( new HookTransform ( ) ) . pipe ( {
175+ write ( chunk ) {
176+ consumeChunk ( chunk ) ; // $ MISSING: flow=transform-hook
177+ return true ;
178+ }
179+ } ) ;
175180
176181class OverriddenWriteDestination extends Writable {
177182 write ( chunk ) {
@@ -261,7 +266,12 @@ const transformOptions = {
261266const transformOptionsAlias = transformOptions ;
262267const { Transform : ImportedTransform } = require ( "node:stream" ) ;
263268const optionsTransform = new ImportedTransform ( transformOptionsAlias ) ;
264- Readable . from ( [ source ( "options-transform" ) ] ) . pipe ( optionsTransform ) ;
269+ Readable . from ( [ source ( "options-transform" ) ] ) . pipe ( optionsTransform ) . pipe ( {
270+ write ( chunk ) {
271+ consumeChunk ( chunk ) ; // $ MISSING: flow=options-transform
272+ return true ;
273+ }
274+ } ) ;
265275
266276const optionsDuplex = new Duplex ( {
267277 read ( ) { } ,
@@ -297,3 +307,38 @@ overriddenOptionsDestination.write = function(chunk) {
297307 return true ;
298308} ;
299309Readable . from ( [ source ( "options-public-write" ) ] ) . pipe ( overriddenOptionsDestination ) ;
310+
311+ class PushingTransform extends Transform {
312+ _transform ( chunk , encoding , callback ) {
313+ this . push ( chunk ) ;
314+ callback ( ) ;
315+ }
316+ }
317+ Readable . from ( [ source ( "transform-push" ) ] ) . pipe ( new PushingTransform ( ) ) . pipe ( {
318+ write ( chunk ) {
319+ consumeChunk ( chunk ) ; // $ MISSING: flow=transform-push
320+ return true ;
321+ }
322+ } ) ;
323+
324+ Readable . from ( [ source ( "dropped-transform-input" ) ] ) . pipe ( new Transform ( {
325+ transform ( chunk , encoding , callback ) {
326+ callback ( ) ;
327+ }
328+ } ) ) . pipe ( {
329+ write ( chunk ) {
330+ consumeChunk ( chunk ) ;
331+ return true ;
332+ }
333+ } ) ;
334+
335+ Readable . from ( [ source ( "replaced-transform-input" ) ] ) . pipe ( new Transform ( {
336+ transform ( chunk , encoding , callback ) {
337+ callback ( null , source ( "replacement-output" ) ) ;
338+ }
339+ } ) ) . pipe ( {
340+ write ( chunk ) {
341+ consumeChunk ( chunk ) ; // $ MISSING: flow=replacement-output
342+ return true ;
343+ }
344+ } ) ;
0 commit comments