File tree Expand file tree Collapse file tree 3 files changed +9
-4
lines changed Expand file tree Collapse file tree 3 files changed +9
-4
lines changed Original file line number Diff line number Diff line change 15
15
use Psr \Log \LoggerInterface ;
16
16
use Symfony \Bridge \PhpUnit \ExpectDeprecationTrait ;
17
17
use Symfony \Component \DependencyInjection \Container ;
18
+ use Symfony \Component \DependencyInjection \ContainerBuilder ;
18
19
use Symfony \Component \HttpFoundation \Request ;
19
20
use Symfony \Component \HttpKernel \Controller \ContainerControllerResolver ;
20
21
Original file line number Diff line number Diff line change @@ -305,8 +305,8 @@ public function testVerifyRequestStackPushPopDuringHandle()
305
305
$ request = new Request ();
306
306
307
307
$ stack = $ this ->getMockBuilder ('Symfony\Component\HttpFoundation\RequestStack ' )->setMethods (['push ' , 'pop ' ])->getMock ();
308
- $ stack ->expects ($ this ->at ( 0 ))->method ('push ' )->with ($ this ->equalTo ($ request ));
309
- $ stack ->expects ($ this ->at ( 1 ))->method ('pop ' );
308
+ $ stack ->expects ($ this ->once ( ))->method ('push ' )->with ($ this ->equalTo ($ request ));
309
+ $ stack ->expects ($ this ->once ( ))->method ('pop ' );
310
310
311
311
$ dispatcher = new EventDispatcher ();
312
312
$ kernel = $ this ->getHttpKernel ($ dispatcher , null , $ stack );
Original file line number Diff line number Diff line change 15
15
use Symfony \Component \Config \Loader \LoaderInterface ;
16
16
use Symfony \Component \DependencyInjection \Compiler \CompilerPassInterface ;
17
17
use Symfony \Component \DependencyInjection \ContainerBuilder ;
18
+ use Symfony \Component \DependencyInjection \ContainerInterface ;
18
19
use Symfony \Component \Filesystem \Filesystem ;
19
20
use Symfony \Component \HttpFoundation \Request ;
20
21
use Symfony \Component \HttpFoundation \Response ;
@@ -167,9 +168,12 @@ public function testShutdownCallsShutdownOnAllBundles()
167
168
public function testShutdownGivesNullContainerToAllBundles ()
168
169
{
169
170
$ bundle = $ this ->getMockBuilder ('Symfony\Component\HttpKernel\Bundle\Bundle ' )->getMock ();
170
- $ bundle ->expects ($ this ->at ( 3 ))
171
+ $ bundle ->expects ($ this ->exactly ( 2 ))
171
172
->method ('setContainer ' )
172
- ->with (null );
173
+ ->withConsecutive (
174
+ [$ this ->isInstanceOf (ContainerInterface::class)],
175
+ [null ]
176
+ );
173
177
174
178
$ kernel = $ this ->getKernel (['getBundles ' ]);
175
179
$ kernel ->expects ($ this ->any ())
You can’t perform that action at this time.
0 commit comments