public DataImportController(DataContext db, ICategoryService categoryService, IProductFinder productFinder, IProductService productService) : base(db) { this.categoryService = categoryService; this.productFinder = productFinder; this.productService = productService; }
public ProductController(ISettingService settings, ICategoryService categoryService, IProductFinder productFinder, IUploadService uploadService) { this.settings = settings; this.categoryService = categoryService; this.productFinder = productFinder; this.uploadService = uploadService; }
public ProductController(DataContext db, IProductFinder productFinder, IDeleterService deleterService, IProductService productService, ITaxClassService taxClassService, ISettingService settingService) : base(db) { this.productFinder = productFinder; this.deleterService = deleterService; this.productService = productService; this.taxClassService = taxClassService; this.settingService = settingService; }
public ProductService(DataContext db, IProductFinder productFinder, ICategoryService categoryService, IProductSkuService productSkuService, ICacheService cacheService) { this.db = db; this.productFinder = productFinder; this.categoryService = categoryService; this.productSkuService = productSkuService; this.cacheService = cacheService; }
public DataExportService() { // Not using structuremap as dependencies are being disposed too early db = DataContext.Create(); categoryService = new CategoryService(db, null, new CacheService()); productFinder = new ProductFinder(db, categoryService); workProcessService = new WorkProcessService(db); }
public void FindProduct_ReturnsNothing() { IProductFinder productFinder = BuildEmptyInventory(); // Act var result = productFinder.FindProduct("barcodeDoesntExist"); result.Should().BeNull(); }
public void FindProduct_ReturnsStuff() { Product prod = new Product("existingBarcode", 10); IProductFinder productFinder = BuildInventoryWith(prod); // Act var result = productFinder.FindProduct("existingBarcode"); result.Should().Be(prod); }
public OrderController(DataContext db, ICustomerService customerService, IProductFinder productFinder, IShippingService shippingService, ITaxService taxService, ISettingService settingService, IOrderService orderService, IOptionService optionService) : base(db) { this.customerService = customerService; this.productFinder = productFinder; this.shippingService = shippingService; this.taxService = taxService; this.settingService = settingService; this.orderService = orderService; this.optionService = optionService; }
public CashRegister(IProductFinder productFinder) { _productFinder = productFinder; }
public ProductService(IProductFinder productFinder) { _productFinder = productFinder; }
public App(IConfiguration configuration, IProductFinder productFinder) { Configuration = configuration ?? throw new ArgumentNullException(nameof(configuration)); ProductFinder = productFinder ?? throw new ArgumentNullException(nameof(productFinder)); }
public ProductService(IUnitOfWork unitOfWork, IRepository <Product> repository, IProductFinder finder) { _unitOfWork = unitOfWork; _repository = repository; _finder = finder; }
public ProductController(IProductFinder productFinder) { _productFinder = productFinder; }