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