Exemplo n.º 1
0
 public function testClearSpecific()
 {
     $cache = Controller_Frontend_Factory::setCache(true);
     $context = TestHelper::getContext();
     $basket1 = Controller_Frontend_Factory::createController($context, 'basket');
     $catalog1 = Controller_Frontend_Factory::createController($context, 'catalog');
     Controller_Frontend_Factory::clear((string) $context, 'basket');
     $basket2 = Controller_Frontend_Factory::createController($context, 'basket');
     $catalog2 = Controller_Frontend_Factory::createController($context, 'catalog');
     Controller_Frontend_Factory::setCache($cache);
     $this->assertNotSame($basket1, $basket2);
     $this->assertSame($catalog1, $catalog2);
 }
Exemplo n.º 2
0
 /**
  * Tears down the fixture, for example, closes a network connection.
  * This method is called after a test is executed.
  *
  * @access protected
  */
 protected function tearDown()
 {
     unset($this->_object);
     Controller_Frontend_Factory::clear();
     MShop_Factory::clear();
 }