Ejemplo n.º 1
0
        public void ValidateCalculateSubscriptionPrice_5lv([Random(min: 65, max: 122, count: 1)]
                                                           int ageInput)
        {
            decimal actualPrice = TransportSubscriptionCardPriceCalculator.CalculateSubscriptionPrice(ageInput.ToString());

            Assert.AreEqual(5, actualPrice);
        }
Ejemplo n.º 2
0
        public void ValidateCalculateSubscriptionPrice_40lv([Random(min: 19, max: 64, count: 1)]
                                                            int ageInput)
        {
            var actualPrice = TransportSubscriptionCardPriceCalculator.CalculateSubscriptionPrice(ageInput.ToString());

            Assert.AreEqual(40, actualPrice);
        }
Ejemplo n.º 3
0
        public void ValidateCalculateSubscriptionPrice_InvalidGreater122()
        {
            decimal actualPrice = TransportSubscriptionCardPriceCalculator.CalculateSubscriptionPrice("1000");

            Assert.AreEqual(5, actualPrice);
        }
Ejemplo n.º 4
0
        public void ValidateCalculateSubscriptionPrice_NotInteger()
        {
            decimal actualPrice = TransportSubscriptionCardPriceCalculator.CalculateSubscriptionPrice("invalid");

            Assert.AreEqual(5, actualPrice);
        }
Ejemplo n.º 5
0
        public void ValidateCalculateSubscriptionPrice1(string ageInput, decimal expectedPrice)
        {
            decimal actualPrice = TransportSubscriptionCardPriceCalculator.CalculateSubscriptionPrice(ageInput);

            Assert.AreEqual(expectedPrice, actualPrice);
        }
Ejemplo n.º 6
0
        ////[ExpectedException(typeof(ArgumentException), ExpectedMessage = GreaterThanZeroExpectionMessage)]
        public void ValidateCalculateSubscriptionPrice_InvalidZero()
        {
            var actualPrice = TransportSubscriptionCardPriceCalculator.CalculateSubscriptionPrice("0");

            Assert.AreEqual(5, actualPrice);
        }