Beispiel #1
0
        private SetDriverForOrderCommandHandler CreateTestedComponent(
            AppSettings appSettings,
            IDbExecutorFactory dbExecutorFactory)
        {
            var logger = Substitute.For <ILogger <SetDriverForOrderCommandHandler> >();

            return(new SetDriverForOrderCommandHandler(logger, appSettings, dbExecutorFactory));
        }
Beispiel #2
0
        public SetDriverForOrderCommandHandler(
            ILogger <SetDriverForOrderCommandHandler> logger,
            AppSettings appSettings,
            IDbExecutorFactory dbExecutorFactory)
        {
            _logger            = logger;
            _appSettings       = appSettings;
            _dbExecutorFactory = dbExecutorFactory;

            _driverByIdQueryFactory = new DriverByIdQuery.Factory();
        }
Beispiel #3
0
 protected OpsTask()
 {
     DbFactory = new SqlDbExecutorFactory();
 }
 /// <summary>
 /// Set custom IDbExecutorFactory
 /// </summary>
 /// <param name="dbExecutorFactory"></param>
 protected void SetDbExecutorFactory(IDbExecutorFactory dbExecutorFactory)
 {
     DbExecutorFactory = dbExecutorFactory;
 }
 /// <summary>
 /// Set DapperDbExecutorFactory as default
 /// </summary>
 protected void SetDbExecutorFactory()
 {
     DbExecutorFactory = new DapperDbExecutorFactory();
 }
Beispiel #6
0
 protected OpsTask()
 {
     DbFactory = new SqlDbExecutorFactory();
 }
 public DbEventStore(IDbExecutorFactory dbExecutorFactory)
 {
     _dbExecutorFactory = dbExecutorFactory ?? throw new ArgumentNullException(nameof(dbExecutorFactory));
 }