public CanAccessCohortQueryHandlerTestsFixture SetNonMatchingQuery() { Query = new CanAccessCohortQuery { CohortId = _cohortId + 1, Party = Party.Provider, PartyId = _accountId }; return(this); }
public CanAccessCohortQueryHandlerTestsFixture SetMatchingAccountQuery() { Query = new CanAccessCohortQuery { CohortId = _cohortId, Party = Party.Employer, PartyId = _accountId }; return(this); }
public CanAccessCohortQueryHandlerTestsFixture SetMatchingProviderQuery() { Query = new CanAccessCohortQuery { CohortId = _cohortId, Party = Party.Provider, PartyId = _providerId }; return(this); }
public async Task <IActionResult> CanAccessCohort(CohortAccessRequest request) { var query = new CanAccessCohortQuery { CohortId = request.CohortId, Party = request.Party, PartyId = request.PartyId }; return(Ok(await _mediator.Send(query))); }