public async void get_team_member_role_return_null() { TeamMembersClient teamMembersClient = new TeamMembersClient(ACCESS_KEY, SECRET_KEY, TenantName.ONEBLINK_TEST); Role role = await teamMembersClient.GetTeamMemberRole("*****@*****.**"); Assert.Null(role); }
public async void can_get_team_member_role() { TeamMembersClient teamMembersClient = new TeamMembersClient(ACCESS_KEY, SECRET_KEY, TenantName.ONEBLINK_TEST); Role role = await teamMembersClient.GetTeamMemberRole(this.email); Assert.NotNull(role); }
public async void get_team_member_role_should_throw_oneblink_exception() { OneBlinkAPIException oneBlinkAPIException = await Assert.ThrowsAsync <OneBlinkAPIException>(() => { TeamMembersClient teamMembersClient = new TeamMembersClient("123", "aaaaaaaaaaaaaaabbbbbbbbbbbbbbbcccccccccccccccc", TenantName.ONEBLINK_TEST); return(teamMembersClient.GetTeamMemberRole(this.email)); }); Assert.Equal(HttpStatusCode.Unauthorized, oneBlinkAPIException.StatusCode); }