예제 #1
0
 public function setUp()
 {
     parent::setUp();
     $this->viewHelper = $this->getAccessibleMock('Tx_Fluid_ViewHelpers_IfViewHelper', array('renderThenChild', 'renderElseChild'));
     $this->injectDependenciesIntoViewHelper($this->viewHelper);
     $this->viewHelper->initializeArguments();
 }
 public function setUp()
 {
     parent::setUp();
     $this->templateVariableContainer = new Tx_Fluid_Core_ViewHelper_TemplateVariableContainer();
     $this->viewHelper = $this->getAccessibleMock('Tx_Fluid_ViewHelpers_RenderViewHelper', array('dummy'));
     $this->injectDependenciesIntoViewHelper($this->viewHelper);
 }
 public function setUp()
 {
     parent::setUp();
     $this->viewHelper = $this->getMock('Tx_Fluid_ViewHelpers_CycleViewHelper', array('renderChildren'));
     $this->injectDependenciesIntoViewHelper($this->viewHelper);
     $this->viewHelper->initializeArguments();
 }
 public function setUp()
 {
     parent::setUp();
     $this->viewHelper = $this->getAccessibleMock('Tx_Fluid_ViewHelpers_Form_SubmitViewHelper', array('dummy'));
     $this->injectDependenciesIntoViewHelper($this->viewHelper);
     $this->viewHelper->initializeArguments();
 }
 public function setUp()
 {
     parent::setUp();
     $this->viewHelper = new Tx_CzSimpleCal_ViewHelpers_Format_DateTimeViewHelper();
     $this->defaultTimezone = date_default_timezone_get();
     date_default_timezone_set('GMT');
 }
 public function setUp()
 {
     parent::setUp();
     $this->viewHelper = $this->getAccessibleMock('Tx_Fluid_ViewHelpers_Form_HiddenViewHelper', array('setErrorClassAttribute', 'getName', 'getValue', 'registerFieldNameForFormTokenGeneration'));
     $this->injectDependenciesIntoViewHelper($this->viewHelper);
     $this->viewHelper->initializeArguments();
 }
 public function setUp()
 {
     parent::setUp();
     $this->viewHelper = new Tx_Fluid_ViewHelpers_Form_SubmitViewHelper();
     $this->injectDependenciesIntoViewHelper($this->viewHelper);
     $this->viewHelper->initializeArguments();
 }
 public function setUp()
 {
     parent::setUp();
     $this->viewHelper = $this->getAccessibleMock('Tx_Fluid_Core_ViewHelper_AbstractConditionViewHelper', array('getRenderingContext', 'renderChildren'));
     $this->viewHelper->expects($this->any())->method('getRenderingContext')->will($this->returnValue($this->renderingContext));
     $this->injectDependenciesIntoViewHelper($this->viewHelper);
 }
 public function setUp()
 {
     parent::setUp();
     $this->cObjBackup = $GLOBALS['TSFE']->cObj;
     $GLOBALS['TSFE']->cObj = $this->getMock('tslib_cObj', array(), array(), '', FALSE);
     $this->viewHelper = $this->getMock($this->buildAccessibleProxy('Tx_Fluid_ViewHelpers_Link_EmailViewHelper'), array('renderChildren'));
     $this->injectDependenciesIntoViewHelper($this->viewHelper);
     $this->viewHelper->initializeArguments();
 }
 public function setUp()
 {
     parent::setUp();
     $this->cObjBackup = $GLOBALS['TSFE']->cObj;
     $GLOBALS['TSFE']->cObj = $this->getMock('tslib_cObj', array(), array(), '', FALSE);
     $this->viewHelper = new Tx_Fluid_ViewHelpers_Uri_EmailViewHelper();
     $this->injectDependenciesIntoViewHelper($this->viewHelper);
     $this->viewHelper->initializeArguments();
 }
 public function setUp()
 {
     parent::setUp();
     $this->tsfeBackup = isset($GLOBALS['TSFE']) ? $GLOBALS['TSFE'] : NULL;
     $GLOBALS['TSFE'] = new stdClass();
     $this->viewHelper = $this->getAccessibleMock('Tx_Fluid_ViewHelpers_Security_IfAuthenticatedViewHelper', array('renderThenChild', 'renderElseChild'));
     $this->viewHelper->expects($this->any())->method('renderThenChild')->will($this->returnValue('then child'));
     $this->viewHelper->expects($this->any())->method('renderElseChild')->will($this->returnValue("else child"));
     $this->injectDependenciesIntoViewHelper($this->viewHelper);
     $this->viewHelper->initializeArguments();
 }
 public function setUp()
 {
     parent::setUp();
     $this->beUserBackup = isset($GLOBALS['BE_USER']) ? $GLOBALS['BE_USER'] : NULL;
     $GLOBALS['BE_USER'] = new stdClass();
     $GLOBALS['BE_USER']->userGroups = array(array('uid' => 1, 'title' => 'Editor'), array('uid' => 2, 'title' => 'OtherRole'));
     $this->viewHelper = $this->getAccessibleMock('Tx_Fluid_ViewHelpers_Be_Security_IfHasRoleViewHelper', array('renderThenChild', 'renderElseChild'));
     $this->viewHelper->expects($this->any())->method('renderThenChild')->will($this->returnValue('then child'));
     $this->viewHelper->expects($this->any())->method('renderElseChild')->will($this->returnValue("else child"));
     $this->injectDependenciesIntoViewHelper($this->viewHelper);
     $this->viewHelper->initializeArguments();
 }
 public function setUp()
 {
     parent::setUp();
     $this->tsfeBackup = isset($GLOBALS['TSFE']) ? $GLOBALS['TSFE'] : NULL;
     $GLOBALS['TSFE'] = new stdClass();
     $GLOBALS['TSFE']->loginUser = 1;
     $GLOBALS['TSFE']->fe_user->groupData = array('uid' => array(1, 2), 'title' => array('Editor', 'OtherRole'));
     $this->viewHelper = $this->getAccessibleMock('Tx_Fluid_ViewHelpers_Security_IfHasRoleViewHelper', array('renderThenChild', 'renderElseChild'));
     $this->viewHelper->expects($this->any())->method('renderThenChild')->will($this->returnValue('then child'));
     $this->viewHelper->expects($this->any())->method('renderElseChild')->will($this->returnValue("else child"));
     $this->injectDependenciesIntoViewHelper($this->viewHelper);
     $this->viewHelper->initializeArguments();
 }
 public function setUp()
 {
     parent::setUp();
     $this->initViewHelper();
 }
 public function setUp()
 {
     parent::setUp();
     $this->viewHelper = new Tx_CzSimpleCal_ViewHelpers_SetGlobalDataViewHelper();
     $this->oldGlobalData = $GLOBALS['TSFE']->cObj->data;
 }
 public function setUp()
 {
     parent::setUp();
     $this->viewHelper = new Tx_CzSimpleCalTests_Mock_ViewHelpers_Format_TimespanToWordsViewHelper();
 }
 public function setUp()
 {
     parent::setUp();
     $this->viewHelper = new Tx_CzSimpleCal_ViewHelpers_Array_JoinViewHelper();
 }
 public function setUp()
 {
     parent::setUp();
     $this->viewHelper = new Tx_CzSimpleCal_ViewHelpers_Format_NumberChoiceViewHelper();
 }
 public function setUp()
 {
     parent::setUp();
     $this->viewHelper = new Tx_CzSimpleCal_ViewHelpers_UseMicroformatViewHelper();
     $this->oldHeaderData = $GLOBALS['TSFE']->additionalHeaderData;
 }