Beispiel #1
0
        public FixedRateMortgageTest()
        {
            var purchasedAt           = new DateTime(2019, 1, 1);
            var mortgageAmount        = 328000.00M;
            var mortgageAmountMoney   = new Money(mortgageAmount, purchasedAt);
            var preferredInterestRate = 0.0319M;

            Subject = new FixedRateMortgage(mortgageAmountMoney, preferredInterestRate, 300, purchasedAt);
        }
Beispiel #2
0
        public static IMortgage GetFixedRateMortgage(decimal baseValue, decimal interestRate, int amortisationPeriodInMonths, DateTime initiatedAt, decimal downPayment)
        {
            var result = new FixedRateMortgage(
                baseValue,
                interestRate,
                amortisationPeriodInMonths,
                initiatedAt
                );

            return(ConvertToInsuredMortgageIfInsurable(result, downPayment));
        }