Ejemplo n.º 1
0
 public function testSetBlockTheme()
 {
     $theme = 'MyBungle::blocks.html.twig';
     $view = new BlockView();
     $this->innerRenderer->expects($this->once())->method('setTheme')->with($this->identicalTo($view), $theme);
     $this->renderer->setBlockTheme($view, $theme);
 }
Ejemplo n.º 2
0
 /**
  * @param TwigRendererInterface $innerRenderer
  * @param FormRendererEngineInterface $formRendererEngine
  * @param \Twig_Environment $environment
  */
 public function __construct(TwigRendererInterface $innerRenderer, FormRendererEngineInterface $formRendererEngine, \Twig_Environment $environment)
 {
     $innerRenderer->setEnvironment($environment);
     parent::__construct($innerRenderer, $formRendererEngine);
 }
Ejemplo n.º 3
0
 public function testSetFormTheme()
 {
     $theme = 'MyBundle::forms.html.twig';
     $this->formRenderer->expects($this->once())->method('addDefaultThemes')->with($theme);
     $this->renderer->setFormTheme($theme);
 }
Ejemplo n.º 4
0
 /**
  * @param TwigRendererInterface $innerRenderer
  * @param \Twig_Environment     $environment
  */
 public function __construct(TwigRendererInterface $innerRenderer, \Twig_Environment $environment)
 {
     $innerRenderer->setEnvironment($environment);
     parent::__construct($innerRenderer);
 }