Beispiel #1
0
        public HomeController(
            IHtmlLocalizer <HomeController> htmlLocalizer,
            IStringLocalizer <HomeController> stringLocalizer,
            ISpamSettingsStore <SpamSettings> spamSettingsStore,
            IAuthorizationService authorizationService,
            IEntityReplyStore <DocComment> entityReplyStore,
            IPlatoUserStore <User> platoUserStore,
            IOptions <PlatoOptions> platoOpts,
            IEntityStore <Doc> entityStore,
            IContextFacade contextFacade,
            ISpamChecker spamChecker,
            ISpamClient spamClient,
            IAlerter alerter)
        {
            _authorizationService = authorizationService;
            _spamSettingsStore    = spamSettingsStore;
            _entityReplyStore     = entityReplyStore;
            _platoUserStore       = platoUserStore;
            _contextFacade        = contextFacade;
            _platoOpts            = platoOpts.Value;
            _spamChecker          = spamChecker;
            _entityStore          = entityStore;
            _spamClient           = spamClient;
            _alerter = alerter;

            T = htmlLocalizer;
            S = stringLocalizer;
        }
 public void SetUp()
 {
     Controller = new WikiController
                      {
                          Repository = Repository,
                          SpamChecker = SpamChecker = Substitute.For<ISpamChecker>(),
                          ControllerContext = ControllerContext,
                          SettingsProvider = SettingsProvider
                      };
 }
Beispiel #3
0
 public void SetUp()
 {
     Controller = new WikiController
     {
         Repository        = Repository,
         SpamChecker       = SpamChecker = Substitute.For <ISpamChecker>(),
         ControllerContext = ControllerContext,
         SettingsProvider  = SettingsProvider
     };
 }
Beispiel #4
0
 public LoginOperator(ISpamChecker spamChecker,
                      INotificationManager <User> notificationManager,
                      IPlatoUserStore <User> platoUserStore,
                      IDeferredTaskManager deferredTaskManager,
                      IUserNotificationTypeDefaults userNotificationTypeDefaults)
 {
     _spamChecker                  = spamChecker;
     _notificationManager          = notificationManager;
     _platoUserStore               = platoUserStore;
     _deferredTaskManager          = deferredTaskManager;
     _userNotificationTypeDefaults = userNotificationTypeDefaults;
 }
Beispiel #5
0
        public void Setup()
        {
            AdminController = new WikiAdminController
            {
                Repository        = Repository = Substitute.For <IRepository>(),
                SpamChecker       = SpamChecker = Substitute.For <ISpamChecker>(),
                ControllerContext = ControllerContext = ControllerContext
            };

            Identity = Substitute.For <IIdentity>();
            User     = Substitute.For <IPrincipal>();
            User.Identity.Returns(Identity);
            ControllerContext.HttpContext.User.Returns(User);
        }
        public void Setup()
        {
            AdminController = new WikiAdminController
                                  {
                                      Repository = Repository = Substitute.For<IRepository>(),
                                      SpamChecker = SpamChecker = Substitute.For<ISpamChecker>(),
                                      ControllerContext = ControllerContext = ControllerContext
                                  };

            Identity = Substitute.For<IIdentity>();
            User = Substitute.For<IPrincipal>();
            User.Identity.Returns(Identity);
            ControllerContext.HttpContext.User.Returns(User);
        }
Beispiel #7
0
 public ReplyOperator(
     IUserNotificationTypeDefaults userNotificationTypeDefaults,
     INotificationManager <Reply> notificationManager,
     IDeferredTaskManager deferredTaskManager,
     IPlatoUserStore <User> platoUserStore,
     IEntityReplyStore <Reply> replyStore,
     ISpamChecker spamChecker)
 {
     _userNotificationTypeDefaults = userNotificationTypeDefaults;
     _notificationManager          = notificationManager;
     _deferredTaskManager          = deferredTaskManager;
     _platoUserStore = platoUserStore;
     _spamChecker    = spamChecker;
     _replyStore     = replyStore;
 }
Beispiel #8
0
 public TopicOperator(
     IUserNotificationTypeDefaults userNotificationTypeDefaults,
     INotificationManager <Topic> notificationManager,
     IDeferredTaskManager deferredTaskManager,
     IPlatoUserStore <User> platoUserStore,
     IClientIpAddress clientIpAddress,
     IEntityStore <Topic> topicStore,
     ISpamChecker spamChecker)
 {
     _userNotificationTypeDefaults = userNotificationTypeDefaults;
     _deferredTaskManager          = deferredTaskManager;
     _notificationManager          = notificationManager;
     _clientIpAddress = clientIpAddress;
     _platoUserStore  = platoUserStore;
     _spamChecker     = spamChecker;
     _topicStore      = topicStore;
 }
Beispiel #9
0
 public AdminViewProvider(
     ISpamChecker spamChecker)
 {
     _spamChecker = spamChecker;
 }