/**
  * {@inheritdoc}
  */
 protected function setUp()
 {
     // Setup a mock container builder.
     $this->containerBuilder = $this->prophesize('\\Symfony\\Component\\DependencyInjection\\ContainerBuilder');
     $this->containerBuilder->getAliases()->willReturn(array());
     $this->containerBuilder->getParameterBag()->willReturn(new ParameterBag());
     $this->containerBuilder->getDefinitions()->willReturn(NULL);
     $this->containerBuilder->isFrozen()->willReturn(TRUE);
     $definition = array();
     $definition['aliases'] = array();
     $definition['parameters'] = array();
     $definition['services'] = array();
     $definition['frozen'] = TRUE;
     $definition['machine_format'] = $this->machineFormat;
     $this->containerDefinition = $definition;
     // Create the dumper.
     $this->dumper = new $this->dumperClass($this->containerBuilder->reveal());
 }
Example #2
0
 protected function setUp()
 {
     $this->container = $this->prophesize(ContainerBuilder::class);
     $this->locator = $this->prophesize(FileLocatorInterface::class);
     $this->loader = new JsonLoader($this->container->reveal(), $this->locator->reveal());
 }