public List <Denomination> GetDenominationValue() { IDenominationLogic logic = new DenominationLogic(); var denominations = logic.GetDenominationValue(); return(denominations); }
public void GetDenominationValueTest() { IDenominationLogic logic = new DenominationLogic(); var denominations = logic.GetDenominationValue(); Assert.AreEqual(12, denominations.Count); }
public void GetDenominationTotalTest() { IDenominationLogic logic = new DenominationLogic(); var total = logic.GetDenominationTotal(); Assert.AreEqual(4638, total); }
public void WithdrawMoneyMaxTest() { var defauklProcess = new ProcessWithdrawal(); var den = defauklProcess.WithdrawMoney(4638d); Assert.AreEqual(12, den.Count); Assert.AreEqual(4638d, den.Sum(x => x.Quantity * x.Value)); IDenominationLogic logic = new DenominationLogic(); var denominations = logic.GetDenominationValue(); // no money left Assert.AreEqual(0, denominations.Sum(x => x.Quantity * x.Value)); }