Cocoa-Puffs commented on code in PR #4884:
URL: https://github.com/apache/fineract/pull/4884#discussion_r2239647746


##########
fineract-e2e-tests-runner/src/test/resources/features/LoanCBR.feature:
##########
@@ -1721,12 +1721,12 @@ Feature: Credit Balance Refund
     When Admin sets the business date to "24 March 2025"
     When Customer makes "PAYOUT_REFUND" transaction with "AUTOPAY" payment 
type on "24 March 2025" with 286.19 EUR transaction amount and system-generated 
Idempotency key
     Then Loan Repayment schedule has 4 periods, with the following data for 
periods:
-      | Nr | Days | Date          | Paid date     | Balance of loan | 
Principal due | Interest | Fees | Penalties | Due    | Paid   | In advance | 
Late  | Outstanding |
-      |    |      | 14 March 2024 |               | 487.58          |          
     |          | 0.0  |           | 0.0    | 0.0    |            |       |     
        |
-      | 1  | 0    | 14 March 2024 | 14 March 2024 | 365.58          | 122.0    
     | 0.0      | 0.0  | 0.0       | 122.0  | 122.0  | 0.0        | 0.0   | 0.0 
        |
-      | 2  | 15   | 29 March 2024 | 24 March 2025 | 243.58          | 122.0    
     | 0.0      | 0.0  | 0.0       | 122.0  | 122.0  | 0.0        | 122.0 | 0.0 
        |
-      | 3  | 15   | 13 April 2024 | 24 March 2025 | 121.58          | 122.0    
     | 0.0      | 0.0  | 0.0       | 122.0  | 122.0  | 79.81      | 42.19 | 0.0 
        |
-      | 4  | 15   | 28 April 2024 | 24 March 2024 | 0.0             | 121.58   
     | 0.0      | 0.0  | 0.0       | 121.58 | 121.58 | 121.58     | 0.0   | 0.0 
        |
+      | Nr | Days | Date          | Paid date     | Balance of loan | 
Principal due | Interest | Fees | Penalties | Due    | Paid   | In advance | 
Late   | Outstanding |
+      |    |      | 14 March 2024 |               | 487.58          |          
     |          | 0.0  |           | 0.0    | 0.0    |            |        |    
         |
+      | 1  | 0    | 14 March 2024 | 14 March 2024 | 365.58          | 122.0    
     | 0.0      | 0.0  | 0.0       | 122.0  | 122.0  | 0.0        | 0.0    | 
0.0         |

Review Comment:
   Because this is a non-interest bearing loan, previously disbursements were 
handled without using the EMI model. In the 
`recalculateRepaymentInstallmentsWithoutEMICalculation` method we have some 
rounding logic based on `installmentAmountInMultiplesOf` of the loan. So 
previously the periods got rounded to whole numbers (in case of 
installmentAmountInMultiplesOf = 1). Now with the EMI calculator we can just 
calculate the exact emi for the periods.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to