| Total Complexity | 8 |
| Total Lines | 33 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 13 | class MemcachedTest extends CacheTest |
||
| 14 | { |
||
| 15 | public static function setUpBeforeClass(): void |
||
| 16 | { |
||
| 17 | if (!extension_loaded('memcached')) { |
||
| 18 | self::markTestSkipped('Required extension "memcached" is not loaded'); |
||
| 19 | } |
||
| 20 | |||
| 21 | // check whether memcached is running and skip tests if not. |
||
| 22 | if (!@stream_socket_client('127.0.0.1:11211', $errorNumber, $errorDescription, 0.5)) { |
||
| 23 | self::markTestSkipped('No memcached server running at ' . '127.0.0.1:11211' . ' : ' . $errorNumber . ' - ' . $errorDescription); |
||
| 24 | } |
||
| 25 | } |
||
| 26 | |||
| 27 | protected function createCacheInstance(): CacheInterface |
||
| 30 | } |
||
| 31 | |||
| 32 | public function testExpire(): void |
||
| 38 | } |
||
| 39 | |||
| 40 | public function testExpireAdd(): void |
||
| 48 |