예제 #1
0
        public void CalculateTotalCost_CalculateBreadOrderCost_Integer()
        {
            Bread bread1 = new Bread("multigrain", 7, 5);
            Bread bread2 = new Bread("white", 1, 4);

            Assert.AreEqual(29, Bread.CalculateTotalCost());
        }
예제 #2
0
 static void Main()
 {
     Console.WriteLine("Welcome to Pierre's Bakery!\n");
     Console.WriteLine("We have delicios products and nice prices!\n");
     Console.WriteLine("You can order bread loaves for buy 2, get 1 free! A single loaf costs depends on bread choice");
     Console.WriteLine("And you can order pastries for buy 2, get 1 for only $1! A single pastry costs depends on pastry choice\n");
     Console.WriteLine("Would you like to order bread? Y/N");
     GetBreadOrder();
     Console.WriteLine("Would you like to order pastry? Y/N");
     GetPastryOrder();
     Console.WriteLine("\nYou ordered: " + GetOrderInfo());
     Console.WriteLine("Total price of your order is: $" + (Bread.CalculateTotalCost() + Pastry.CalculateTotalCost()));
 }