friendica/tests/src/Core/Cache/MemcacheCacheDriverTest.php
Philipp Holzer eafcf3592d
Config FollowUp
- 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
2019-02-17 20:40:27 +01:00

36 lines
650 B
PHP

<?php
namespace Friendica\Test\src\Core\Cache;
use Friendica\Core\Cache\CacheDriverFactory;
/**
* @requires extension memcache
*/
class MemcacheCacheDriverTest extends MemoryCacheTest
{
protected function getInstance()
{
$this->configCache
->shouldReceive('get')
->with('system', 'memcache_host', NULL, false)
->andReturn('localhost');
$this->configCache
->shouldReceive('get')
->with('system', 'memcache_port', NULL, false)
->andReturn(11211);
$this->cache = CacheDriverFactory::create('memcache');
return $this->cache;
}
public function tearDown()
{
$this->cache->clear(false);
parent::tearDown();
}
}