friendica/tests/src/Core/Lock/RedisCacheLockDriverTest.php
Philipp Holzer 433d6abe8c
Refactoring DBA-mocking tests
- Reducing DB-dependencies
- Creating DB-cache mocks
- Creating DB-lock mocks
- Switching to mocked dependencies for Cache/Lock/App
2019-02-02 19:03:15 +01:00

24 lines
519 B
PHP

<?php
namespace Friendica\Test\src\Core\Lock;
use Friendica\Core\Cache\CacheDriverFactory;
use Friendica\Core\Lock\CacheLockDriver;
/**
* @requires extension redis
* @runTestsInSeparateProcesses
* @preserveGlobalState disabled
*/
class RedisCacheLockDriverTest extends LockTest
{
protected function getInstance()
{
$this->mockConfigGet('system', 'redis_host', 'localhost', 1);
$this->mockConfigGet('system', 'redis_port', null, 1);
return new CacheLockDriver(CacheDriverFactory::create('redis'));
}
}