TestCccExtension example

$this->fail('An exception should have been thrown.');
        } catch (\Exception $e) {
        }

        $this->assertSame(['FOO']array_keys($container->getParameterBag()->getEnvPlaceholders()));
    }

    public function testReuseEnvPlaceholderGeneratedByPreviousExtension()
    {
        $container = new ContainerBuilder();
        $container->registerExtension(new FooExtension());
        $container->registerExtension(new TestCccExtension());
        $container->prependExtensionConfig('foo', ['bool_node' => '%env(bool:MY_ENV_VAR)%']);
        $container->prependExtensionConfig('test_ccc', ['bool_node' => '%env(bool:MY_ENV_VAR)%']);

        (new MergeExtensionConfigurationPass())->process($container);

        $this->addToAssertionCount(1);
    }
}

class FooConfiguration implements ConfigurationInterface
{
    
Home | Imprint | This part of the site doesn't use cookies.