public function DefinitionTest::testSetIsSynthetic in Service Container 7
Same name and namespace in other branches
- 7.2 modules/providers/service_container_symfony/lib/Symfony/Component/DependencyInjection/Tests/DefinitionTest.php \Symfony\Component\DependencyInjection\Tests\DefinitionTest::testSetIsSynthetic()
@covers Symfony\Component\DependencyInjection\Definition::setSynthetic @covers Symfony\Component\DependencyInjection\Definition::isSynthetic
File
- modules/
providers/ service_container_symfony/ lib/ Symfony/ Component/ DependencyInjection/ Tests/ DefinitionTest.php, line 158
Class
Namespace
Symfony\Component\DependencyInjection\TestsCode
public function testSetIsSynthetic() {
$def = new Definition('stdClass');
$this
->assertFalse($def
->isSynthetic(), '->isSynthetic() returns false by default');
$this
->assertSame($def, $def
->setSynthetic(true), '->setSynthetic() implements a fluent interface');
$this
->assertTrue($def
->isSynthetic(), '->isSynthetic() returns true if the service is synthetic.');
}