Exemple #1
0
 /**
  * Sets up the fixture, for example, open a network connection.
  * This method is called before a test is executed.
  *
  * @return void
  */
 public function setUp()
 {
     $this->clearRegistry();
     $this->_cache = Cache\Cache::factory('Core', 'File', array('lifetime' => 120, 'automatic_serialization' => true), array('cache_dir' => sys_get_temp_dir()));
     Currency\Currency::setCache($this->_cache);
     $this->helper = new Helper\Currency('de_AT');
 }
Exemple #2
0
 public function setUp()
 {
     $this->_cache = Cache\Cache::factory('Core', 'File',
         array('lifetime' => 120, 'automatic_serialization' => true),
         array('cache_dir' => __DIR__ . '/../_files/'));
     Currency\Currency::setCache($this->_cache);
 }
Exemple #3
0
 public function setUp()
 {
     $this->_cacheDir = sys_get_temp_dir() . '/zend_currency';
     $this->_removeRecursive($this->_cacheDir);
     mkdir($this->_cacheDir);
     $this->_cache = CacheFactory::factory(array('adapter' => array('name' => 'Filesystem', 'options' => array('ttl' => 120, 'cache_dir' => $this->_cacheDir)), 'plugins' => array(array('name' => 'serializer', 'options' => array('serializer' => 'php_serialize')))));
     Currency\Currency::setCache($this->_cache);
 }
Exemple #4
0
    /**
     * Sets up the fixture, for example, open a network connection.
     * This method is called before a test is executed.
     *
     * @return void
     */
    public function setUp()
    {
        $this->clearRegistry();

        $this->_cache = CacheFactory::adapterFactory('memory', array('memory_limit' => 0));
        Currency\Currency::setCache($this->_cache);

        $this->helper = new Helper\Currency('de_AT');
    }
Exemple #5
0
 public function setUp()
 {
     $this->_cache = CacheFactory::adapterFactory('memory', array('memory_limit' => 0));
     Currency\Currency::setCache($this->_cache);
 }
Exemple #6
0
 public function setUp()
 {
     $cache = Cache\Cache::factory('Core', 'File', array('lifetime' => 120, 'automatic_serialization' => true), array('cache_dir' => dirname(__FILE__) . '/_files/'));
     Currency\Currency::setCache($cache);
 }