You are here

public function PhpDumperTest::testLegacySynchronizedServices in Service Container 7

Same name and namespace in other branches
  1. 7.2 modules/providers/service_container_symfony/lib/Symfony/Component/DependencyInjection/Tests/Dumper/PhpDumperTest.php \Symfony\Component\DependencyInjection\Tests\Dumper\PhpDumperTest::testLegacySynchronizedServices()

@group legacy

File

modules/providers/service_container_symfony/lib/Symfony/Component/DependencyInjection/Tests/Dumper/PhpDumperTest.php, line 130

Class

PhpDumperTest

Namespace

Symfony\Component\DependencyInjection\Tests\Dumper

Code

public function testLegacySynchronizedServices() {
  $this
    ->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED);
  $container = (include self::$fixturesPath . '/containers/container20.php');
  $dumper = new PhpDumper($container);
  $this
    ->assertEquals(str_replace('%path%', str_replace('\\', '\\\\', self::$fixturesPath . DIRECTORY_SEPARATOR . 'includes' . DIRECTORY_SEPARATOR), file_get_contents(self::$fixturesPath . '/php/services20.php')), $dumper
    ->dump(), '->dump() dumps services');
}