/// <summary> /// Obtiene todos los usuarios /// </summary> /// <returns>UserList</returns> internal static UserList GetAllUsers(bool?pActiveflag) { SearchAllUsersReq req = new SearchAllUsersReq(); //req.BusinessData.Activeflag = pActiveflag; SearchAllUsersRes res = req.ExecuteService <SearchAllUsersReq, SearchAllUsersRes>(WrapperSecurityProvider, req); if (res.Error != null) { throw Fwk.Exceptions.ExceptionHelper.ProcessException(res.Error); } return(res.BusinessData.UserList); }
public void SearchAllUsersService_WithProvider() { string strErrorResult = string.Empty; SearchAllUsersReq req = new SearchAllUsersReq(); SearchAllUsersRes res = ClientServiceBase.ExecuteService <SearchAllUsersReq, SearchAllUsersRes>("XML_test", req); if (res.Error != null) { strErrorResult = Fwk.Exceptions.ExceptionHelper.ProcessException(res.Error).Message; } Assert.AreEqual <Fwk.Exceptions.ServiceError>(res.Error, null, strErrorResult); }
public void SearchAllUsersService_WithProvider() { string strErrorResult = string.Empty; SearchAllUsersReq req = new SearchAllUsersReq(); SearchAllUsersRes res = ClientServiceBase.ExecuteService<SearchAllUsersReq, SearchAllUsersRes>("XML_test",req); if (res.Error != null) { strErrorResult = Fwk.Exceptions.ExceptionHelper.ProcessException(res.Error).Message; } Assert.AreEqual<Fwk.Exceptions.ServiceError>(res.Error, null, strErrorResult); }
public void SearchAllUsers_NoService() { string strErrorResult = string.Empty; SearchAllUsersService svc = new SearchAllUsersService(); SearchAllUsersReq req = new SearchAllUsersReq(); try { SearchAllUsersRes res = svc.Execute(req); } catch (Exception ex) { strErrorResult = Fwk.Exceptions.ExceptionHelper.GetAllMessageException(ex); } Assert.AreEqual<String>(strErrorResult, string.Empty, strErrorResult); }
public void SearchAllUsers_NoService() { string strErrorResult = string.Empty; SearchAllUsersService svc = new SearchAllUsersService(); SearchAllUsersReq req = new SearchAllUsersReq(); try { SearchAllUsersRes res = svc.Execute(req); } catch (Exception ex) { strErrorResult = Fwk.Exceptions.ExceptionHelper.GetAllMessageException(ex); } Assert.AreEqual <String>(strErrorResult, string.Empty, strErrorResult); }
/// <summary> /// Obtiene todos los usuarios /// </summary> /// <returns>UserList</returns> internal static UserList GetAllUsers(bool? pActiveflag) { SearchAllUsersReq req = new SearchAllUsersReq(); //req.BusinessData.Activeflag = pActiveflag; SearchAllUsersRes res = req.ExecuteService<SearchAllUsersReq, SearchAllUsersRes>(WrapperSecurityProvider, req); if (res.Error != null) { throw Fwk.Exceptions.ExceptionHelper.ProcessException(res.Error); } return res.BusinessData.UserList; }