Files
yii2/tests/unit/framework/caching/ZendDataCacheTest.php
Alexander Makarov 7cd9123c3b Tests cleanup
- Better names
- Removed not used MySQLTestCase
- Moved base testcase for DB to db namespace
- Minor style fixes
2013-05-24 18:35:00 +04:00

28 lines
561 B
PHP

<?php
namespace yiiunit\framework\caching;
use yii\caching\Cache;
use yii\caching\ZendDataCache;
/**
* Class for testing Zend cache backend
*/
class ZendDataCacheTest extends CacheTestCase
{
private $_cacheInstance = null;
/**
* @return ZendDataCache
*/
protected function getCacheInstance()
{
if (!function_exists("zend_shm_cache_store")) {
$this->markTestSkipped("Zend Data cache not installed. Skipping.");
}
if ($this->_cacheInstance === null) {
$this->_cacheInstance = new ZendDataCache();
}
return $this->_cacheInstance;
}
}