public void ComputeNumberOfProducts_Should_Correctly_Integrate_With_ProductRepository() { // Arrange _statisticGenerator = new StorageStatisticsGenerator(new ProductRepository()); // Act _statisticGenerator.ComputeNumberOfProducts(); // Assert _productRepository.Verify(p => p.LoadProducts()); }
public void Setup() { _productRepository = new Mock <IProductRepository>(); _statisticGenerator = new StorageStatisticsGenerator(_productRepository.Object); }