/** * Remove a Color. * * @param Color|Identity $id * * @throws ColorNotFoundException */ public function remove(Identity $id) { $result = parent::find($id); if (null === $result) { throw new ColorNotFoundException(); } parent::remove($id); }
public function testFindReturnsNullIfNotFound() { $this->assertNull($this->repository->find(new ObjectId(99999))); }