public function testRemove() { $cacheId = 'test'; $this->_model->save('test data', $cacheId); $this->assertGreaterThan(0, $this->_model->test($cacheId), "Cache with id '{$cacheId}' has not been found"); $this->_model->remove($cacheId); $this->assertFalse($this->_model->test($cacheId), "Cache with id '{$cacheId}' has not been removed"); }
public function testRemove() { $cacheId = 'test'; $this->_collection->expects($this->once())->method('remove')->with(['_id' => $cacheId])->will($this->returnValue(true)); $this->assertTrue($this->_model->remove($cacheId)); }