@@ -291,11 +291,11 @@ public function testValidMimeType()
291291 $ file
292292 ->expects ($ this ->once ())
293293 ->method ('getPathname ' )
294- ->will ($ this ->returnValue ( $ this -> path ) );
294+ ->willReturn ($ this ->path );
295295 $ file
296296 ->expects ($ this ->once ())
297297 ->method ('getMimeType ' )
298- ->will ( $ this -> returnValue ( 'image/jpg ' ) );
298+ ->willReturn ( 'image/jpg ' );
299299
300300 $ constraint = new File ([
301301 'mimeTypes ' => ['image/png ' , 'image/jpg ' ],
@@ -315,11 +315,11 @@ public function testValidWildcardMimeType()
315315 $ file
316316 ->expects ($ this ->once ())
317317 ->method ('getPathname ' )
318- ->will ($ this ->returnValue ( $ this -> path ) );
318+ ->willReturn ($ this ->path );
319319 $ file
320320 ->expects ($ this ->once ())
321321 ->method ('getMimeType ' )
322- ->will ( $ this -> returnValue ( 'image/jpg ' ) );
322+ ->willReturn ( 'image/jpg ' );
323323
324324 $ constraint = new File ([
325325 'mimeTypes ' => ['image/* ' ],
@@ -339,11 +339,11 @@ public function testInvalidMimeType()
339339 $ file
340340 ->expects ($ this ->once ())
341341 ->method ('getPathname ' )
342- ->will ($ this ->returnValue ( $ this -> path ) );
342+ ->willReturn ($ this ->path );
343343 $ file
344344 ->expects ($ this ->once ())
345345 ->method ('getMimeType ' )
346- ->will ( $ this -> returnValue ( 'application/pdf ' ) );
346+ ->willReturn ( 'application/pdf ' );
347347
348348 $ constraint = new File ([
349349 'mimeTypes ' => ['image/png ' , 'image/jpg ' ],
@@ -369,11 +369,11 @@ public function testInvalidWildcardMimeType()
369369 $ file
370370 ->expects ($ this ->once ())
371371 ->method ('getPathname ' )
372- ->will ($ this ->returnValue ( $ this -> path ) );
372+ ->willReturn ($ this ->path );
373373 $ file
374374 ->expects ($ this ->once ())
375375 ->method ('getMimeType ' )
376- ->will ( $ this -> returnValue ( 'application/pdf ' ) );
376+ ->willReturn ( 'application/pdf ' );
377377
378378 $ constraint = new File ([
379379 'mimeTypes ' => ['image/* ' , 'image/jpg ' ],
0 commit comments