processLoadExtension example



                $container->import('../Fixtures/config/services.php');
            }

            public function getAlias(): string
            {
                return 'micro';
            }
        };

        $container = $this->processLoadExtension($extension[['foo' => 'bar']]);

        self::assertSame(['foo' => 'bar']$container->getParameter('foo_param'));
        self::assertTrue($container->hasDefinition('foo_service'));
        self::assertTrue($container->hasDefinition('bar_service'));
    }

    protected function processConfiguration(ConfigurableInterface $configurable): array
    {
        $configuration = new Configuration($configurable, null, 'micro');

        return (new Processor())->process($configuration->getConfigTreeBuilder()->buildTree()[]);
    }
Home | Imprint | This part of the site doesn't use cookies.