protected override void Context()
        {
            var product1 = new Mock<Product>();
            product1.SetupGet(x => x.Price).Returns(10m);
            product1.SetupGet(x => x.Color).Returns(Color.Green);

            var product2 = new Mock<Product>();
            product2.SetupGet(x => x.Price).Returns(20m);
            product2.SetupGet(x => x.Color).Returns(Color.Red);

            var products = new List<Product> {product1.Object, product2.Object};
            _productFilter = new ProductFilter(products);
        }
        protected override void Context()
        {
            var product1 = new Mock <Product>();

            product1.SetupGet(x => x.Price).Returns(10m);
            product1.SetupGet(x => x.Color).Returns(Color.Green);

            var product2 = new Mock <Product>();

            product2.SetupGet(x => x.Price).Returns(20m);
            product2.SetupGet(x => x.Color).Returns(Color.Red);

            var products = new List <Product> {
                product1.Object, product2.Object
            };

            _productFilter = new ProductFilter(products);
        }
Ejemplo n.º 3
0
 public Consumer()
 {
     Filter = new ProductFilter(new List<Product>());
 }
Ejemplo n.º 4
0
 public Consumer()
 {
     Filter = new ProductFilter(new List <Product>());
 }