Exemplo n.º 1
0
        public void AddDiscountToFamilyIncrementsInOne()
        {
            Family family = new SubscriptionFactory().familyThreeDiscounts;

            Assert.IsTrue(family.TotalDiscount() == 3);
            family.AddDiscountType(new SubscriptionFactory().weekly);
            Assert.IsTrue(family.TotalDiscount() == 4);
        }
Exemplo n.º 2
0
        public void AddingMoreThanFiveDiscountsToFamilyThrowsException()
        {
            Family family = new SubscriptionFactory().familyFiveDiscounts;

            Assert.IsTrue(family.TotalDiscount() == 5);
            family.AddDiscountType(new SubscriptionFactory().hourly);
        }