Example #1
0
 /**
  * Create Cache database for UnitTesting and init self::$cache
  * has Zend_Cache ready to use instance
  *
  * @return void
  */
 protected static function _initUnitTestCache()
 {
     // init once only
     if (isset(self::$cache)) {
         return;
     }
     // set cache options
     $frontendOptions = array('lifetime' => 7200, 'automatic_serialization' => true);
     $backendOptions = array('cache_dir' => BaseZF_UnitTest_TemporaryFile::getTmpPath());
     // create cache
     self::$cache = Zend_Cache::factory('Core', 'File', $frontendOptions, $backendOptions);
 }