コード例 #1
0
 /**
  * Tests adding the bundle services to the container.
  */
 public function testLoad()
 {
     $container = new ContainerBuilder();
     $params = ['contao' => ['encryption_key' => 'foobar']];
     $this->extension->load($params, $container);
     $this->assertTrue($container->has('contao.listener.output_from_cache'));
     $this->assertTrue($container->has('contao.listener.add_to_search_index'));
 }
コード例 #2
0
 /**
  * Tests adding the bundle services to the container.
  */
 public function testLoad()
 {
     $container = new ContainerBuilder(new ParameterBag(['kernel.debug' => false]));
     $params = ['contao' => ['encryption_key' => 'foobar', 'localconfig' => ['foo' => 'bar']]];
     $extension = new ContaoCoreExtension();
     $extension->load($params, $container);
     $this->assertTrue($container->has('contao.listener.add_to_search_index'));
 }