/** * Setup fixture * @author Sebastian Kurfürst <*****@*****.**> */ public function setUp() { $this->renderingContext = new Tx_Fluid_Core_Rendering_RenderingContext(); $this->mockObjectManager = $this->getMock('Tx_Extbase_Object_ObjectManagerInterface'); $this->renderingContext->injectObjectManager($this->mockObjectManager); $this->templateVariableContainer = $this->getMock('Tx_Fluid_Core_ViewHelper_TemplateVariableContainer'); $this->renderingContext->setTemplateVariableContainer($this->templateVariableContainer); $this->controllerContext = $this->getMock('Tx_Extbase_MVC_Controller_ControllerContext', array(), array(), '', FALSE); $this->renderingContext->setControllerContext($this->controllerContext); $this->viewHelperVariableContainer = $this->getMock('Tx_Fluid_Core_ViewHelper_ViewHelperVariableContainer'); $this->renderingContext->setViewHelperVariableContainer($this->viewHelperVariableContainer); }
/** * @test * @author Sebastian Kurfürst <*****@*****.**> */ public function viewHelperVariableContainerCanBeReadCorrectly() { $viewHelperVariableContainer = $this->getMock('Tx_Fluid_Core_ViewHelper_ViewHelperVariableContainer'); $this->renderingContext->setViewHelperVariableContainer($viewHelperVariableContainer); $this->assertSame($viewHelperVariableContainer, $this->renderingContext->getViewHelperVariableContainer()); }