public void Cook(Vegetable vegetable) { Potato potato = new Potato(); potato.Peel(); potato.Cut(); Carrot carrot = new Carrot(); carrot.Peel(); carrot.Cut(); Bowl bowl = new Bowl(); bowl.Add(potato); bowl.Add(carrot); }
public void Cook() { Potato potato = GetPotato(); Carrot carrot = GetCarrot(); Bowl bowl = GetBowl(); potato.Peel(); carrot.Peel(); Cut(potato); Cut(carrot); bowl.Add(carrot); bowl.Add(potato); }
public void CookTest() { // Base code refactored functionally goes below Potato potato = new Potato(); Carrot carrot = new Carrot(); Bowl bowl = new Bowl(); potato.Peel(); carrot.Peel(); potato.Cut(); carrot.Cut(); bowl.Add(carrot); bowl.Add(potato); // task2 - Potato COOKING! - included in the base code this.Cook(bowl.Ingredients); }
public void CookTest() { // Base code refactored functionally goes below Potato potato = new Potato(); Carrot carrot = new Carrot(); Bowl bowl = new Bowl(); potato.Peel(); carrot.Peel(); potato.Cut(); carrot.Cut(); bowl.Add(carrot); bowl.Add(potato); // task2 - Potato COOKING! - included in the base code this.Cook(bowl.Ingredients); }
public void Cook() { Potato potato = this.GetPotato(); Carrot carrot = this.GetCarrot(); List <Vegetable> veggies = new List <Vegetable>() { potato, carrot }; Bowl bowl; bowl = this.GetBowl(veggies); potato.Peel(); carrot.Peel(); potato.Cut(); carrot.Cut(); bowl.Add(carrot); bowl.Add(potato); }