public void RoleManagementLogic_UpdateRole_Unauthorized_ThrowsUnauthorizedAccessException()
        {
            SecurityRole    securityRole = new SecurityRole();
            ClaimsPrincipal user         = new ClaimsPrincipal();

            Mock <IAuthorizationLogic> authorizationLogic = new Mock <IAuthorizationLogic>();

            authorizationLogic.Setup(x => x.IsAuthorizedThrowsException(AuthorizationScopes.ManageRoles, user, It.IsAny <ILoggableEntity>(), It.IsAny <EventCategory>())).Throws(new UnauthorizedAccessException());

            Mock <IConfigurationRepository> configurationRepository = new Mock <IConfigurationRepository>();

            RoleManagementLogic roleManagementLogic = new RoleManagementLogic(configurationRepository.Object, authorizationLogic.Object);

            roleManagementLogic.UpdateRole(securityRole, user);
        }
 public JsonResult UpdateRole(SecurityRole entity)
 {
     roleManagement.UpdateRole(entity, User);
     return(http.RespondSuccess());
 }