- New Configuration (Config is now only holding the instance) - New PConfiguration (PConfig is now only holding the instance) - Config & PConfig-Adapter don't need "ConfigCache" anymore - DB-Connection is now outside App->reload() for better dependency-chaining
34 lines
633 B
PHP
34 lines
633 B
PHP
<?php
|
|
|
|
|
|
namespace Friendica\Test\src\Core\Cache;
|
|
|
|
use Friendica\Core\Cache\CacheDriverFactory;
|
|
|
|
/**
|
|
* @requires extension redis
|
|
*/
|
|
class RedisCacheDriverTest extends MemoryCacheTest
|
|
{
|
|
protected function getInstance()
|
|
{
|
|
$this->configCache
|
|
->shouldReceive('get')
|
|
->with('system', 'redis_host', NULL, false)
|
|
->andReturn('localhost');
|
|
|
|
$this->configCache
|
|
->shouldReceive('get')
|
|
->with('system', 'redis_port', NULL, false)
|
|
->andReturn(null);
|
|
|
|
$this->cache = CacheDriverFactory::create('redis');
|
|
return $this->cache;
|
|
}
|
|
|
|
public function tearDown()
|
|
{
|
|
$this->cache->clear(false);
|
|
parent::tearDown();
|
|
}
|
|
}
|