Пример #1
0
        public void SetUp()
        {
            _dao       = A.Fake <ISpfPeriodicSchedulerDao>();
            _publisher = A.Fake <IMessagePublisher>();
            _config    = A.Fake <ISpfPeriodicSchedulerConfig>();
            _log       = A.Fake <ILogger <SpfPollSchedulerProcessor> >();

            _sut = new SpfPollSchedulerProcessor(_dao, _publisher, _config, _log);
        }
Пример #2
0
 public SpfPollSchedulerProcessor(ISpfPeriodicSchedulerDao dao,
                                  IMessagePublisher publisher,
                                  ISpfPeriodicSchedulerConfig config,
                                  ILogger <SpfPollSchedulerProcessor> log)
 {
     _dao       = dao;
     _publisher = publisher;
     _config    = config;
     _log       = log;
 }
Пример #3
0
        protected override void SetUp()
        {
            base.SetUp();

            TruncateDatabase().Wait();

            IConnectionInfoAsync connectionInfoAsync = A.Fake <IConnectionInfoAsync>();

            A.CallTo(() => connectionInfoAsync.GetConnectionStringAsync()).Returns(ConnectionString);

            ISpfPeriodicSchedulerConfig config = A.Fake <ISpfPeriodicSchedulerConfig>();

            A.CallTo(() => config.RefreshIntervalSeconds).Returns(0);
            A.CallTo(() => config.DomainBatchSize).Returns(10);

            _dao = new SpfPeriodicSchedulerDao(connectionInfoAsync, config);
        }
 public SpfPeriodicSchedulerDao(IConnectionInfoAsync connectionInfo, ISpfPeriodicSchedulerConfig config)
 {
     _connectionInfo = connectionInfo;
     _config         = config;
 }