public void Setup()
        {
            _commandHandler = Substitute.For <IProductCommandHandler>();
            _repository     = Substitute.For <IProductRepository>();

            _sut = new ProductController(_commandHandler, _repository);
        }
예제 #2
0
 public ProductController(
     ILogger <ProductController> logger,
     IProductCommandHandler productCommandHandler,
     IProductQueryHandler productQueryHandler)
 {
     _logger = logger;
     _productCommandHandler = productCommandHandler;
     _productQueryHandler   = productQueryHandler;
 }
 public ProductController(IProductCommandHandler commandHandler,
                          IProductRepository repository)
 {
     _commandHandler = commandHandler;
     _repository     = repository;
 }