/** * {@inheritdoc} */ public function exists() { if (false === $this->memcached->get($this->storeId)) { return MemcachedClient::RES_SUCCESS === $this->memcached->getResultCode(); } return true; }
/** @test */ public function itShouldWriteToAndReadFromCache() { $store = new Storage($this->memcached, $this->storeId); $store->write($this->mockRoutes()); $this->assertInstanceOf('Lucid\\Mux\\Cache\\CachedCollectionInterface', $store->read()); }