public function KernelTest::testInitializeBundleThrowsExceptionWhenABundleExtendsItself

@expectedException \LogicException

File

drupal/core/vendor/symfony/http-kernel/Symfony/Component/HttpKernel/Tests/KernelTest.php, line 749

Class

KernelTest

Namespace

Symfony\Component\HttpKernel\Tests

Code

public function testInitializeBundleThrowsExceptionWhenABundleExtendsItself() {
  $circularRef = $this
    ->getBundle(null, 'CircularRefBundle', 'CircularRefBundle');
  $kernel = $this
    ->getKernel();
  $kernel
    ->expects($this
    ->once())
    ->method('registerBundles')
    ->will($this
    ->returnValue(array(
    $circularRef,
  )));
  $kernel
    ->initializeBundles();
}