@@ -126,18 +126,6 @@ public function testRemoveWriteStreamAfterWriting()
126126 $ this ->tickLoop ($ this ->loop );
127127 }
128128
129- public function testRemoveStreamInstantly ()
130- {
131- list ($ input , $ output ) = $ this ->createSocketPair ();
132-
133- $ this ->loop ->addReadStream ($ input , $ this ->expectCallableNever ());
134- $ this ->loop ->addWriteStream ($ input , $ this ->expectCallableNever ());
135- $ this ->loop ->removeStream ($ input );
136-
137- fwrite ($ output , "bar \n" );
138- $ this ->tickLoop ($ this ->loop );
139- }
140-
141129 public function testRemoveStreamForReadOnly ()
142130 {
143131 list ($ input , $ output ) = $ this ->createSocketPair ();
@@ -163,30 +151,13 @@ public function testRemoveStreamForWriteOnly()
163151 $ this ->tickLoop ($ this ->loop );
164152 }
165153
166- public function testRemoveStream ()
167- {
168- list ($ input , $ output ) = $ this ->createSocketPair ();
169-
170- $ this ->loop ->addReadStream ($ input , $ this ->expectCallableOnce ());
171- $ this ->loop ->addWriteStream ($ input , $ this ->expectCallableOnce ());
172-
173- fwrite ($ output , "bar \n" );
174- $ this ->tickLoop ($ this ->loop );
175-
176- $ this ->loop ->removeStream ($ input );
177-
178- fwrite ($ output , "bar \n" );
179- $ this ->tickLoop ($ this ->loop );
180- }
181-
182154 public function testRemoveInvalid ()
183155 {
184156 list ($ stream ) = $ this ->createSocketPair ();
185157
186158 // remove a valid stream from the event loop that was never added in the first place
187159 $ this ->loop ->removeReadStream ($ stream );
188160 $ this ->loop ->removeWriteStream ($ stream );
189- $ this ->loop ->removeStream ($ stream );
190161 }
191162
192163 /** @test */
@@ -202,7 +173,7 @@ public function runShouldReturnWhenNoMoreFds()
202173
203174 $ loop = $ this ->loop ;
204175 $ this ->loop ->addReadStream ($ input , function ($ stream ) use ($ loop ) {
205- $ loop ->removeStream ($ stream );
176+ $ loop ->removeReadStream ($ stream );
206177 });
207178
208179 fwrite ($ output , "foo \n" );
@@ -366,7 +337,7 @@ public function testRunWaitsForFutureTickEvents()
366337 $ this ->loop ->addWriteStream (
367338 $ stream ,
368339 function () use ($ stream ) {
369- $ this ->loop ->removeStream ($ stream );
340+ $ this ->loop ->removeWriteStream ($ stream );
370341 $ this ->loop ->futureTick (
371342 function () {
372343 echo 'future-tick ' . PHP_EOL ;
0 commit comments