public function testDeleteUserImageMethod() { $imageId = 'image123'; $params = array('userimage' => $imageId); $this->_mockXmlRpcClient('deleteUserimage', true, $params); $this->assertTrue($this->_gravatarXmlRpc->deleteUserImage($imageId)); }
/** * Sets $_rating. * * @param int|string $rating * @return void */ public function setRating($rating) { $validRatings = NP_Service_Gravatar_XmlRpc::getValidRatings(); if (array_key_exists($rating, $validRatings)) { $this->_rating = $rating; } elseif (in_array($rating, $validRatings)) { $this->_rating = array_search($rating, $validRatings); } else { require_once 'NP/Service/Gravatar/XmlRpc/Exception.php'; throw new NP_Service_Gravatar_XmlRpc_Exception('Invalid rating.'); } }