public void Coin025AddJarTest() { Coin025 coin025 = new Coin025(); Jar jar = new Jar(); //add the 25-cent coin to the jar coin025.AddToJar(jar); //assert jar.Coin025Counter is 1 and jar.CurrentAmount is $0.25 Assert.AreEqual(1, jar.Coin025Counter); Assert.AreEqual(0.25m, jar.CurrentAmount); }
public void FillUpwith25CentCoinTest() { Jar jar = new Jar(); Coin025 coin025 = new Coin025(); //fill up with 25-cent coins while (coin025.AddToJar(jar)) { ; } jar.PrintJar(); }