mirror of
https://github.com/friendica/friendica
synced 2025-02-26 05:58:14 +00:00
33 lines
548 B
PHP
33 lines
548 B
PHP
<?php
|
|
|
|
namespace Friendica\Test\src\Core\Lock;
|
|
|
|
|
|
use Friendica\Core\Cache\ArrayCache;
|
|
use Friendica\Core\Lock\CacheLockDriver;
|
|
|
|
class ArrayCacheLockDriverTest extends LockTest
|
|
{
|
|
/**
|
|
* @var \Friendica\Core\Cache\IMemoryCacheDriver
|
|
*/
|
|
private $cache;
|
|
|
|
protected function getInstance()
|
|
{
|
|
$this->cache = new ArrayCache();
|
|
return new CacheLockDriver($this->cache);
|
|
}
|
|
|
|
public function tearDown()
|
|
{
|
|
$this->cache->clear();
|
|
parent::tearDown();
|
|
}
|
|
|
|
public function testLockTTL()
|
|
{
|
|
// ArrayCache doesn't support TTL
|
|
return true;
|
|
}
|
|
}
|