public function clear(CacheAbstract $cache) { $key = new CacheKey('clear', 'it'); $cd = new CacheData($key, 789); $this->assertTrue($cache->storeData($cd)); $cache->clear(); try { $cache->get($key); $this->fail(); } catch (Cachearium\Exceptions\NotCachedException $e) { $this->assertTrue(true); } }