public void CandyMakesMunchMunchSound() { Candy candy = new Candy("A1", "Snickers", (decimal)1.00, "Candy"); string actualString = candy.MakeSound(); Assert.AreEqual("Munch Munch, Yum!", actualString, "Candy items should make munch sound."); }
public void MakeSoundMethod_Normal() { Candy candy = new Candy("Crunchie", 1.75M); string sound = candy.MakeSound(); Assert.AreEqual("Munch Munch, Yum!", sound); }
public void CandyExpectedSound() { Candy candy = new Candy("Candy Bar", 1); string actual = candy.MakeSound(); Assert.AreEqual("Munch Munch, Yum!", actual, "Make sound for candy"); }
public void MakeSoundMethod_Exceptions() { Candy candy = new Candy("", -1.75M); string sound = candy.MakeSound(); Assert.AreEqual("Munch Munch, Yum!", sound); candy = new Candy(null, -1.0M); sound = candy.MakeSound(); Assert.AreEqual("Munch Munch, Yum!", sound); }
public void TestSound() { Chip testChip = new Chip("doritos", 1.50M); Assert.AreEqual("Crunch, Crunch, Yum!", testChip.MakeSound(), "Didn't make correct sound."); Candy testCandy = new Candy("hersheys", 2.00M); Assert.AreEqual("Munch, Munch, Yum!", testCandy.MakeSound(), "Didn't make correct sound."); Drink testDrink = new Drink("whiskey", 0.50M); Assert.AreEqual("Glug, Glug, Yum!", testDrink.MakeSound(), "Didn't make correct sound."); Gum testGum = new Gum("five", 3.00M); Assert.AreEqual("Chew, Chew, Yum!", testGum.MakeSound(), "Didn't make correct sound."); }
public void MakeSound() { Candy candySound = new Candy("B1", "ChocolateFudge", 1.05M); Assert.AreEqual("Munch Munch, Yum!", candySound.MakeSound()); }