@@ -82,7 +82,7 @@ public function testEmitBody($seekable, $contents, $maxBufferLength, $expectedRe
8282 $ stream ->getContents ()->willReturn ($ contents );
8383 $ stream ->rewind ()->willReturn (true );
8484
85- $ stream ->eof ()->will (function () use (&$ contents , &$ position ) {
85+ $ stream ->eof ()->will (function () use (& $ contents , & $ position ) {
8686 return ! isset ($ contents [$ position ]);
8787 });
8888
@@ -144,7 +144,7 @@ public function testEmitMemoryUsage($seekable, $maxBufferLength, $sizeBlocks, $m
144144 $ peakMemoryUsage = max ($ peakMemoryUsage , memory_get_usage ());
145145 };
146146
147- $ closureFullContents = function () use (&$ sizeBytes ) {
147+ $ closureFullContents = function () use (& $ sizeBytes ) {
148148 return str_repeat ('0 ' , $ sizeBytes );
149149 };
150150
@@ -156,20 +156,20 @@ public function testEmitMemoryUsage($seekable, $maxBufferLength, $sizeBlocks, $m
156156 $ stream ->getContents ()->will ($ closureFullContents );
157157 $ stream ->rewind ()->willReturn (true );
158158
159- $ stream ->seek (Argument::type ('integer ' ), Argument::any ())->will (function ($ args ) use (&$ position ) {
159+ $ stream ->seek (Argument::type ('integer ' ), Argument::any ())->will (function ($ args ) use (& $ position ) {
160160 $ position = $ args [0 ];
161161 return true ;
162162 });
163163
164- $ stream ->eof ()->will (function () use (&$ sizeBytes , &$ position ) {
164+ $ stream ->eof ()->will (function () use (& $ sizeBytes , & $ position ) {
165165 return ($ position >= $ sizeBytes );
166166 });
167167
168- $ stream ->tell ()->will (function () use (&$ position ) {
168+ $ stream ->tell ()->will (function () use (& $ position ) {
169169 return $ position ;
170170 });
171171
172- $ stream ->read (Argument::type ('integer ' ))->will (function ($ args ) use (&$ position , &$ peakBufferLength ) {
172+ $ stream ->read (Argument::type ('integer ' ))->will (function ($ args ) use (& $ position , & $ peakBufferLength ) {
173173 if ($ args [0 ] > $ peakBufferLength ) {
174174 $ peakBufferLength = $ args [0 ];
175175 }
@@ -188,7 +188,7 @@ public function testEmitMemoryUsage($seekable, $maxBufferLength, $sizeBlocks, $m
188188 $ response = $ response ->withHeader ('Content-Range ' , 'bytes ' . $ first . '- ' . $ last . '/* ' );
189189 }
190190
191- ob_start (function ($ output ) use (&$ closureTrackMemoryUsage ) {
191+ ob_start (function ($ output ) use (& $ closureTrackMemoryUsage ) {
192192 call_user_func ($ closureTrackMemoryUsage );
193193 return "" ;
194194 }, $ maxBufferLength );
@@ -234,20 +234,20 @@ public function testEmitBodyRange($seekable, $contents, $range, $maxBufferLength
234234 $ stream ->getContents ()->willReturn ($ contents );
235235 $ stream ->rewind ()->willReturn (true );
236236
237- $ stream ->seek (Argument::type ('integer ' ), Argument::any ())->will (function ($ args ) use (&$ position ) {
237+ $ stream ->seek (Argument::type ('integer ' ), Argument::any ())->will (function ($ args ) use (& $ position ) {
238238 $ position = $ args [0 ];
239239 return true ;
240240 });
241241
242- $ stream ->eof ()->will (function () use (&$ contents , &$ position ) {
242+ $ stream ->eof ()->will (function () use (& $ contents , & $ position ) {
243243 return ! isset ($ contents [$ position ]);
244244 });
245245
246- $ stream ->tell ()->will (function () use (&$ position ) {
246+ $ stream ->tell ()->will (function () use (& $ position ) {
247247 return $ position ;
248248 });
249249
250- $ stream ->read (Argument::type ('integer ' ))->will (function ($ args ) use (&$ contents , &$ position ) {
250+ $ stream ->read (Argument::type ('integer ' ))->will (function ($ args ) use (& $ contents , & $ position ) {
251251 $ data = substr ($ contents , $ position , $ args [0 ]);
252252 $ position += strlen ($ data );
253253 return $ data ;
0 commit comments