@Test
public void testExecuteDeleteMembership() {

    String domainName = "mbrdeldom1";
    String roleName = "role1";
    
    TopLevelDomain dom1 = createTopLevelDomainObject(domainName,
            "Test Domain1", "testOrg", adminUser);
    zms.postTopLevelDomain(mockDomRsrcCtx, auditRef, dom1);
    Role role1 = createRoleObject(domainName, roleName, null,
            "user.joe", "user.jane");
    zms.putRole(mockDomRsrcCtx, domainName, roleName, auditRef, role1);
    zms.dbService.executeDeleteMembership(mockDomRsrcCtx, domainName, roleName,
            "user.joe", auditRef, "deleteMembership");
    Role role = zms.getRole(mockDomRsrcCtx, domainName, roleName, true, false, false);
    assertNotNull(role);
    List<RoleMember> members = role.getRoleMembers();
    assertNotNull(members);
    assertEquals(members.size(), 1);
    for (RoleMember member: members) {
        if (member.getMemberName().equals("user.joe")) {
            fail("user.joe could not be deleted");
        }
    }
    List<String> checkList = new ArrayList<>();
    checkList.add("user.jane");
    checkRoleMember(checkList, members);
    zms.deleteTopLevelDomain(mockDomRsrcCtx, domainName, auditRef);
}