public ActorOrganisationsControllerTests() { var model = new ActorOrganisationViewModel { Id = "5a82f9ffcb969daa58d33377", Type = ActorType.Consumer, Name = "Ambulance Service", ImageUrl = "....", Context = new List <ContentView>() { new ContentView { Title = "Title Text", Content = new List <string> { "Content Text" }, CssClass = "CssClass Text", Order = 1 } }, OrgCode = "AMSR01", Benefits = new List <string> { "benefitid" }, PersonnelLinkId = "testlink" }; var actorOrganisationService = new Mock <IActorOrganisationService>(); actorOrganisationService.Setup(x => x.GetById(It.Is <string>(y => y == "5a82f9ffcb969daa58d33377"))).Returns(Task.Run(() => model)); actorOrganisationService.Setup(x => x.GetById(It.Is <string>(y => y == "5a82f9ffcb969daa58d33378"))).Returns(Task.Run(() => (ActorOrganisationViewModel)null)); _actorOrganisationService = actorOrganisationService.Object; }
public void Dispose() { _actorOrganisationService = null; }
public ActorOrganisationsController(IActorOrganisationService actorOrgService) { _actorOrgService = actorOrgService; }
public BenefitsViewService(IPersonnelService personnelService, IActorOrganisationService actorOrganisationService, IBenefitsService benefitsService) { _personnelService = personnelService; _actorOrganisationService = actorOrganisationService; _benefitsService = benefitsService; }