You are here

public function ContainerBuilderTest::testGetReturnsNullOnInactiveScopeWhenServiceIsCreatedByAMethod in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/symfony/dependency-injection/Tests/ContainerBuilderTest.php \Symfony\Component\DependencyInjection\Tests\ContainerBuilderTest::testGetReturnsNullOnInactiveScopeWhenServiceIsCreatedByAMethod()

@covers Symfony\Component\DependencyInjection\ContainerBuilder::get

File

vendor/symfony/dependency-injection/Tests/ContainerBuilderTest.php, line 158

Class

ContainerBuilderTest

Namespace

Symfony\Component\DependencyInjection\Tests

Code

public function testGetReturnsNullOnInactiveScopeWhenServiceIsCreatedByAMethod() {
  $builder = new ProjectContainer();
  $this
    ->assertNull($builder
    ->get('foobaz', ContainerInterface::NULL_ON_INVALID_REFERENCE));
}