You are here

public function KernelTest::testShutdownGivesNullContainerToAllBundles in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/symfony/http-kernel/Tests/KernelTest.php \Symfony\Component\HttpKernel\Tests\KernelTest::testShutdownGivesNullContainerToAllBundles()

File

vendor/symfony/http-kernel/Tests/KernelTest.php, line 175

Class

KernelTest

Namespace

Symfony\Component\HttpKernel\Tests

Code

public function testShutdownGivesNullContainerToAllBundles() {
  $bundle = $this
    ->getMock('Symfony\\Component\\HttpKernel\\Bundle\\Bundle');
  $bundle
    ->expects($this
    ->at(3))
    ->method('setContainer')
    ->with(null);
  $kernel = $this
    ->getKernel(array(
    'getBundles',
  ));
  $kernel
    ->expects($this
    ->any())
    ->method('getBundles')
    ->will($this
    ->returnValue(array(
    $bundle,
  )));
  $kernel
    ->boot();
  $kernel
    ->shutdown();
}