1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-04-13 20:32:11 +02:00

[ticket/12620] Fix tests

PHPBB3-12620
This commit is contained in:
Tristan Darricau 2014-10-04 17:47:36 +02:00
parent 3a167aa0c3
commit 0b61e3540d
3 changed files with 18 additions and 1 deletions

View File

@ -195,6 +195,8 @@ class container_builder
$loader = new YamlFileLoader($this->container, new FileLocator(phpbb_realpath($this->get_config_path())));
$loader->load(PHPBB_ENVIRONMENT . '/config.yml');
$this->inject_custom_parameters();
if ($this->compile_container)
{
$this->container->compile();
@ -430,6 +432,20 @@ class container_builder
return $container;
}
/**
* Inject the customs parameters into the container
*/
protected function inject_custom_parameters()
{
if ($this->custom_parameters !== null)
{
foreach ($this->custom_parameters as $key => $value)
{
$this->container->setParameter($key, $value);
}
}
}
/**
* Returns the core parameters.
*

View File

@ -146,7 +146,6 @@ namespace
$this->assertInstanceOf('Symfony\Component\DependencyInjection\ContainerBuilder', $container);
$this->assertTrue($container->hasParameter('my_parameter'));
$this->assertFalse($container->hasParameter('core.root_path'));
}
}
}

View File

@ -0,0 +1,2 @@
core:
require_dev_dependencies: true