Exemplo n.º 1
0
        public void ScenarioCTest()
        {
            decimal totalCartAmount = 0.0M, totalPromotionDiscount = 0.0M;

            AddProduct();
            AddPromotionTypes();
            AddScenarioCProductToCart();
            PromotionEngine promotionEngine = new PromotionEngine(_promotionTypes);

            totalCartAmount        = _customerCart.GetTotalCartAmount();
            totalPromotionDiscount = promotionEngine.GetPromotionDiscount(_customerCart.CustomerItems);
            Assert.AreEqual(280, totalCartAmount - totalPromotionDiscount);
        }