public function testListAll() { $mc = MiniCache::getInstance(); $mc->deleteAll(); $tests = array('string' => 'my test string', 'array' => array('my', 'test', 'array'), 'boolean' => TRUE, 'integer' => 35, 'double' => 3.14, 'object' => (object) 'my object'); $cacheKeys = array(); foreach ($tests as $k => $v) { $cacheKey = __CLASS__ . __FUNCTION__ . $k; $cacheKeys[] = MiniCache::cacheKey($cacheKey); $mc->set($cacheKey, $v); } $mc->destroyInstance(); $mc = MiniCache::getInstance(); $listAllResultKeys = array_keys($mc->listAll()); sort($listAllResultKeys); sort($cacheKeys); $this->assertEquals($listAllResultKeys, $cacheKeys); }