public override ActionResult SupportUserBanner(IAccountIdentifier model = null) { EmployerAccounts.Models.Account.Account account = null; if (model != null && model.HashedAccountId != null) { var externalUserId = OwinWrapper.GetClaimValue(ControllerConstants.UserRefClaimKeyName); var response = AsyncHelper.RunSync(() => _employerTeamOrchestrator.GetAccountSummary(model.HashedAccountId, externalUserId)); account = response.Status != HttpStatusCode.OK ? null : response.Data.Account; } var consoleUserType = OwinWrapper.GetClaimValue(ClaimTypes.Role) == "Tier2User" ? "Service user (T2 Support)" : "Standard user"; return(PartialView("_SupportUserBanner", new SupportUserBannerViewModel { Account = account, ConsoleUserType = consoleUserType })); }
public async Task ThenReturnAccountSummary() { var model = await _orchestrator.GetAccountSummary(HashedAccountId, UserId); Assert.IsNotNull(model.Data); }