Пример #1
0
 public function testCreateController()
 {
     $context = TestHelper::getContext();
     $config = $context->getConfig();
     $config->set('controller/frontend/common/decorators/default', array());
     $target = 'Controller_Frontend_Service_Interface';
     $controller = Controller_Frontend_Service_Factory::createController(TestHelper::getContext());
     $this->assertInstanceOf($target, $controller);
     $controller = Controller_Frontend_Service_Factory::createController(TestHelper::getContext(), 'Default');
     $this->assertInstanceOf($target, $controller);
 }
Пример #2
0
 /**
  * Sets up the fixture, for example, opens a network connection.
  * This method is called before a test is executed.
  *
  * @access protected
  */
 protected function setUp()
 {
     $context = TestHelper::getContext();
     $controller = Controller_Frontend_Service_Factory::createController($context, 'Default');
     $this->_object = new Controller_Frontend_Service_Decorator_Example($context, $controller);
 }