Exemple #1
0
        public void Bonus10Percent_LargeThan50_Return5Point1()
        {
            PaymentBonus paymentBonus = new PaymentBonus();

            float result = paymentBonus.Bonus10Percent(51);

            Assert.AreEqual(5.1.ToString(), @String.Format("{0:0.0}", result));
        }
Exemple #2
0
        public void Bonus10Percent_ZeroParameter_NotZero()
        {
            PaymentBonus paymentBonus = new PaymentBonus();

            float result = paymentBonus.Bonus10Percent(0);

            Assert.AreNotEqual(1, result);
        }
Exemple #3
0
        public void Bonus10Percent_ValidParameter_ReturnOne()
        {
            PaymentBonus paymentBonus = new PaymentBonus();

            float result = paymentBonus.Bonus10Percent(10);

            Assert.AreEqual(1, result);
        }