You are here

public function ContainerBuilderTest::testGetServiceIds 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::testGetServiceIds()

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

File

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

Class

ContainerBuilderTest

Namespace

Symfony\Component\DependencyInjection\Tests

Code

public function testGetServiceIds() {
  $builder = new ContainerBuilder();
  $builder
    ->register('foo', 'stdClass');
  $builder->bar = $bar = new \stdClass();
  $builder
    ->register('bar', 'stdClass');
  $this
    ->assertEquals(array(
    'foo',
    'bar',
    'service_container',
  ), $builder
    ->getServiceIds(), '->getServiceIds() returns all defined service ids');
}