Beispiel #1
0
        public void ProductRangeList()
        {
            var rep = new ProductRangeRepository();

            var items = rep.ListByRange(1);

            items.Should().NotBeNullOrEmpty();
        }
Beispiel #2
0
        public ProductControllerTest()
        {
            var productRepository = new ProductRangeRepository(IndexFrom, IndexTo);
            var productManager    = new ProductManager(productRepository);
            var settings          = new ApiControllerSettings()
            {
                DefaultPageSize = PageSize
            };

            var options = Options.Create(settings);

            productController = new ProductController(options, productManager);
        }
        public ProductRangeRepositoryTests()
        {
            container = new PointOfScaleContainer();

            productRangeRepository = new ProductRangeRepository(container);

            container.Products = new List <Product>
            {
                new Product {
                    Code = "A", RetailPrice = 1.25m, VolumePrice = 3m, VolumeQuantity = 3
                },
                new Product {
                    Code = "B", RetailPrice = 4.25m
                },
                new Product {
                    Code = "C", RetailPrice = 1m, VolumePrice = 5m, VolumeQuantity = 6
                },
                new Product {
                    Code = "D", RetailPrice = 0.75m
                }
            };
        }
 public ProductRangeController() : base()
 {
     productRangeRepository = new ProductRangeRepository();
     logger = new SystemLogger();
 }