public function ResolveDefinitionTemplatesPassTest::testSetLazyOnServiceHasParent in Service Container 7.2
Same name and namespace in other branches
- 7 modules/providers/service_container_symfony/lib/Symfony/Component/DependencyInjection/Tests/Compiler/ResolveDefinitionTemplatesPassTest.php \Symfony\Component\DependencyInjection\Tests\Compiler\ResolveDefinitionTemplatesPassTest::testSetLazyOnServiceHasParent()
File
- modules/
providers/ service_container_symfony/ lib/ Symfony/ Component/ DependencyInjection/ Tests/ Compiler/ ResolveDefinitionTemplatesPassTest.php, line 146
Class
Namespace
Symfony\Component\DependencyInjection\Tests\CompilerCode
public function testSetLazyOnServiceHasParent() {
$container = new ContainerBuilder();
$container
->register('parent', 'stdClass');
$container
->setDefinition('child1', new DefinitionDecorator('parent'))
->setLazy(true);
$this
->process($container);
$this
->assertTrue($container
->getDefinition('child1')
->isLazy());
}