@@ -146,66 +146,6 @@ public function itShouldHandlePipingCorrectly()
146146 $ input ->emit ('data ' , array ('foo ' ));
147147 }
148148
149- /** @test */
150- public function itShouldForwardPauseUpstreamWhenPipedTo ()
151- {
152- $ readable = $ this ->getMockBuilder ('React\Stream\ReadableStreamInterface ' )->getMock ();
153- $ readable ->expects ($ this ->any ())->method ('isReadable ' )->willReturn (true );
154- $ writable = $ this ->getMockBuilder ('React\Stream\WritableStreamInterface ' )->getMock ();
155- $ writable ->expects ($ this ->any ())->method ('isWritable ' )->willReturn (true );
156-
157- $ composite = new CompositeStream ($ readable , $ writable );
158-
159- $ input = $ this ->getMockBuilder ('React\Stream\ThroughStream ' )->setMethods (array ('pause ' , 'resume ' ))->getMock ();
160- $ input
161- ->expects ($ this ->once ())
162- ->method ('pause ' );
163-
164- $ input ->pipe ($ composite );
165- $ composite ->pause ();
166- }
167-
168- /** @test */
169- public function itShouldForwardResumeUpstreamWhenPipedTo ()
170- {
171- $ readable = $ this ->getMockBuilder ('React\Stream\ReadableStreamInterface ' )->getMock ();
172- $ readable ->expects ($ this ->any ())->method ('isReadable ' )->willReturn (true );
173- $ writable = $ this ->getMockBuilder ('React\Stream\WritableStreamInterface ' )->getMock ();
174- $ writable ->expects ($ this ->any ())->method ('isWritable ' )->willReturn (true );
175-
176- $ composite = new CompositeStream ($ readable , $ writable );
177-
178- $ input = $ this ->getMockBuilder ('React\Stream\ThroughStream ' )->setMethods (array ('pause ' , 'resume ' ))->getMock ();
179- $ input
180- ->expects ($ this ->once ())
181- ->method ('resume ' );
182-
183- $ input ->pipe ($ composite );
184- $ composite ->resume ();
185- }
186-
187- /** @test */
188- public function itShouldForwardPauseAndResumeUpstreamWhenPipedTo ()
189- {
190- $ readable = $ this ->getMockBuilder ('React\Stream\ReadableStreamInterface ' )->getMock ();
191- $ writable = new ThroughStream ();
192- $ writable ->pause ();
193-
194- $ composite = new CompositeStream ($ readable , $ writable );
195-
196- $ input = $ this ->getMockBuilder ('React\Stream\ThroughStream ' )->setMethods (array ('pause ' , 'resume ' ))->getMock ();
197- $ input
198- ->expects ($ this ->once ())
199- ->method ('pause ' );
200- $ input
201- ->expects ($ this ->once ())
202- ->method ('resume ' );
203-
204- $ input ->pipe ($ composite );
205- $ input ->emit ('data ' , array ('foo ' ));
206- $ writable ->emit ('drain ' );
207- }
208-
209149 /** @test */
210150 public function itShouldForwardPipeCallsToReadableStream ()
211151 {
0 commit comments