Behat\Testwork\Cli\Application::createContainer PHP Method

createContainer() private method

Creates container instance, loads extensions and freezes it.
private createContainer ( Symfony\Component\Console\Input\InputInterface $input, Symfony\Component\Console\Output\OutputInterface $output ) : Symfony\Component\DependencyInjection\ContainerInterface
$input Symfony\Component\Console\Input\InputInterface
$output Symfony\Component\Console\Output\OutputInterface
return Symfony\Component\DependencyInjection\ContainerInterface
    private function createContainer(InputInterface $input, OutputInterface $output)
    {
        $basePath = rtrim($this->getBasePath(), DIRECTORY_SEPARATOR);
        $container = new ContainerBuilder();
        $container->setParameter('cli.command.name', $this->getName());
        $container->setParameter('paths.base', $basePath);
        $container->set('cli.input', $input);
        $container->set('cli.output', $output);
        $extension = new ContainerLoader($this->extensionManager);
        $extension->load($container, $this->loadConfiguration($input));
        $container->addObjectResource($extension);
        $container->compile();
        return $container;
    }