protected override void AdditionalSetup() { base.AdditionalSetup(); BandProcess = MockHelper.CreateAndRegisterMock<IBandProcess>(); UserProcess = MockHelper.CreateAndRegisterMock<IUserProcess>(); UserMapper = MockHelper.CreateAndRegisterMock<IUserMapper>(); CryptographyProcess = MockHelper.CreateAndRegisterMock<ICryptographyProcess>(); CustomMembershipProvider = new CustomMembershipProvider(); }
private async Task ProcessUserAction(List <BulkUser> bulkUsers, string actionFor) { var logConst = "UserScheduleProcessor-ProcessUserAction"; try { IUserProcess userProcess = null; switch (actionFor) { case CareStreamConst.Bulk_User_Create: userProcess = new UserCreate(_logger, _cc); await userProcess.ProcessUser(bulkUsers); break; case CareStreamConst.Bulk_User_Invite: userProcess = new UserInvite(_logger, _cc); await userProcess.ProcessUser(bulkUsers); break; case CareStreamConst.Bulk_User_Update: userProcess = new UserUpdate(_logger, _cc); await userProcess.ProcessUser(bulkUsers); break; case CareStreamConst.Bulk_User_Delete: userProcess = new UserDelete(_logger, _cc); await userProcess.ProcessUser(bulkUsers); break; } } catch (Exception ex) { _logger.LogError($"{logConst}:Exception occured while processing the bulk user..."); _logger.LogError(ex); } }
public UsersController(IUserProcess userProcess) { _userProcess = userProcess; }
public UserService(IUserProcess process) { _process = process; }
public UsersController(IUserProcess userProcess, IOptions <AppSettings> appSettings) { _userProcess = userProcess; _appSettings = appSettings.Value; }
public AuthController(IUserProcess userProcess) { this._userProcess = userProcess; }