$this->
assertEquals(array_keys($expected),
array_keys($actual), '->load() imports and merges imported files'
);
} public function testRegisterClasses() { $container =
new ContainerBuilder();
$container->
setParameter('sub_dir', 'Sub'
);
$loader =
new TestFileLoader($container,
new FileLocator(self::
$fixturesPath.'/Fixtures'
));
$loader->
noAutoRegisterAliasesForSinglyImplementedInterfaces();
$loader->
registerClasses(new Definition(), 'Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\\', 'Prototype/%sub_dir%/*'
);
$loader->
registerClasses(new Definition(), 'Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\\', 'Prototype/%sub_dir%/*'
); // loading twice should not be an issue
$loader->
registerAliasesForSinglyImplementedInterfaces();
$this->
assertEquals( ['service_container', Bar::
class],
array_keys($container->
getDefinitions()) );
$this->
assertEquals([BarInterface::
class],
array_keys($container->
getAliases()));
} public function testRegisterClassesWithExclude() {