예제 #1
0
        public void TotalValue_WhenValidCreditCreated_ShouldBeAddedInterestValue()
        {
            _sut = new FisicalCredit(100, 5, DateTime.Now.AddDays(15).Date);

            _sut.TotalValue.ShouldBe(103);
        }
예제 #2
0
        public void InterestValue_WhenValidCreditCreated_ShouldBePercentageOfValue()
        {
            _sut = new FisicalCredit(100, 5, DateTime.Now.AddDays(15).Date);

            _sut.InterestValue.ShouldBe(3);
        }
예제 #3
0
        public void Validate_WhenCreditCreated(decimal value, int qtdInstallments, DateTime firstDueDate, bool expectedStatus)
        {
            _sut = new FisicalCredit(value, qtdInstallments, firstDueDate);

            _sut.IsApproved.ShouldBe(expectedStatus);
        }