ChrisCScott / forecaster

A personal finances forecasting tool for Canadian retirement planning
Other
1 stars 2 forks source link

Add tests for new Debt property and methods #46

Closed ChrisCScott closed 6 years ago

ChrisCScott commented 6 years ago

36 resulted in adding Debt.living_expense (and renaming Debt.reduction_rate to Debt.savings_rate). It also resulted in adding companion methods Debt.payment and Debt.payment_from_savings.

We should extend __init__ tests to ensure the the new property is being constructed correctly. We should also add tests for the new methods. Be sure to test for out-of-range values (e.g. negative available, available greater than max_inflow).

Consider also adding tests for Debt accounts with a non-default living_expense in both Debt tests and DebtPaymentStrategy tests.