fix redis stats

This commit is contained in:
Dennis Eichhorn 2019-12-07 23:42:57 +01:00
parent 5b61c9718d
commit 7c72a40bde

View File

@ -56,14 +56,9 @@ class RedisCacheTest extends \PHPUnit\Framework\TestCase
self::assertTrue($this->cache->flushAll());
self::assertEquals(0, $this->cache->getThreshold());
self::assertNull($this->cache->get('test'));
self::assertEquals(
[
'status' => CacheStatus::OK,
'count' => 0,
'size' => 0,
],
$this->cache->stats()
);
self::assertEquals(CacheStatus::OK, $this->cache->stats()['status']);
self::assertEquals(0, $this->cache->stats()['count']);
self::assertGreaterThanOrEqual(0, $this->cache->stats()['size']);
}
/**
@ -213,14 +208,9 @@ class RedisCacheTest extends \PHPUnit\Framework\TestCase
self::assertTrue($this->cache->flushAll());
self::assertNull($this->cache->get('key5'));
self::assertEquals(
[
'status' => CacheStatus::OK,
'count' => 0,
'size' => 0,
],
$this->cache->stats()
);
self::assertEquals(CacheStatus::OK, $this->cache->stats()['status']);
self::assertEquals(0, $this->cache->stats()['count']);
self::assertGreaterThanOrEqual(0, $this->cache->stats()['size']);
}
/**