public PurchaseServiceTests() { _fakeAccountRepository = new FakeRepository<Account>(); _fakeOrderRepository = new FakeRepository<Order>(); _fakeProductRepository = new FakeRepository<Product>(); _fakeUnitOfWorkFactory = new FakeUnitOfWorkFactory( uow => { uow.SetRepository(_fakeAccountRepository); uow.SetRepository(_fakeOrderRepository); uow.SetRepository(_fakeProductRepository); }); }
public CashboxCalculatuinDiscountSteps() { _fakeAccountRepository = new FakeRepository<Account>(); _fakeOrderRepository = new FakeRepository<Order>(); _fakeProductRepository = new FakeRepository<Product>(); _fakeUnitOfWorkFactory = new FakeUnitOfWorkFactory( uow => { uow.SetRepository(_fakeAccountRepository); uow.SetRepository(_fakeOrderRepository); uow.SetRepository(_fakeProductRepository); }); _service = new PurchaseService(_fakeUnitOfWorkFactory); TestSetup(); }