public function testUpdateUserProfile_SetLangCode_LangCodeSet() { $this->environ->clean(); // setup parameters $userId = $this->environ->createUser('username', 'name', '*****@*****.**'); $params = array('id' => '', 'interfaceLanguageCode' => 'th'); $newUserId = UserCommands::updateUserProfile($params, $userId); // user profile updated $user = new UserProfileModel($newUserId); $this->assertEqual($user->interfaceLanguageCode, 'th'); $this->assertEqual($userId, $newUserId); }
/** * Create/Update a User Profile * * @param UserProfileModel $json * @return string Id of written object */ public function user_updateProfile($params) { return UserCommands::updateUserProfile($params, $this->_userId); }