Parcourir la source

Merge pull request #3660 from greg0ire/fix_broken_2_3_build

mock Kernel::getContainer()
Oskar Stark il y a 9 ans
Parent
commit
081dffb2bc
1 fichiers modifiés avec 4 ajouts et 0 suppressions
  1. 4 0
      Tests/Command/GenerateAdminCommandTest.php

+ 4 - 0
Tests/Command/GenerateAdminCommandTest.php

@@ -72,6 +72,10 @@ class GenerateAdminCommandTest extends \PHPUnit_Framework_TestCase
             ->with($this->equalTo('AcmeDemoBundle'))
             ->will($this->returnValue($bundle));
 
+        $kernel->expects($this->any())
+            ->method('getContainer')
+            ->will($this->returnValue($this->container));
+
         $this->application = new Application($kernel);
         $this->command = new GenerateAdminCommand();