This is an automated email from the ASF dual-hosted git repository.

adamsaghy pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/fineract.git


The following commit(s) were added to refs/heads/develop by this push:
     new 703ef9010 FINERACT-2081: Loan account data additional fields for 
summary
703ef9010 is described below

commit 703ef9010977e5069d8f04c0979ac56c20fe18f3
Author: Jose Alberto Hernandez <[email protected]>
AuthorDate: Fri Jul 19 02:24:32 2024 -0600

    FINERACT-2081: Loan account data additional fields for summary
---
 .../src/main/avro/loan/v1/LoanSummaryDataV1.avsc                 | 8 ++++++++
 .../integrationtests/CustomSnapshotEventIntegrationTest.java     | 9 ++++++++-
 2 files changed, 16 insertions(+), 1 deletion(-)

diff --git a/fineract-avro-schemas/src/main/avro/loan/v1/LoanSummaryDataV1.avsc 
b/fineract-avro-schemas/src/main/avro/loan/v1/LoanSummaryDataV1.avsc
index 9dae4c2f5..1dfffa539 100644
--- a/fineract-avro-schemas/src/main/avro/loan/v1/LoanSummaryDataV1.avsc
+++ b/fineract-avro-schemas/src/main/avro/loan/v1/LoanSummaryDataV1.avsc
@@ -411,6 +411,14 @@
                 "bigdecimal"
             ]
         },
+        {
+            "default": null,
+            "name": "totalInterestPaymentWaiver",
+            "type": [
+                "null",
+                "bigdecimal"
+            ]
+        },
         {
             "default": null,
             "name": "chargeOffReasonId",
diff --git 
a/integration-tests/src/test/java/org/apache/fineract/integrationtests/CustomSnapshotEventIntegrationTest.java
 
b/integration-tests/src/test/java/org/apache/fineract/integrationtests/CustomSnapshotEventIntegrationTest.java
index f6dd36c2c..98f9ab0b1 100644
--- 
a/integration-tests/src/test/java/org/apache/fineract/integrationtests/CustomSnapshotEventIntegrationTest.java
+++ 
b/integration-tests/src/test/java/org/apache/fineract/integrationtests/CustomSnapshotEventIntegrationTest.java
@@ -95,7 +95,7 @@ public class CustomSnapshotEventIntegrationTest extends 
BaseLoanIntegrationTest
             Assertions.assertEquals(loanId, 
allExternalEvents.get(0).getAggregateRootId());
 
             // Loan Delinquency data validation
-            final Map<String, Object> payLoad = (Map<String, Object>) 
allExternalEvents.get(0).getPayLoad().get("delinquent");
+            Map<String, Object> payLoad = (Map<String, Object>) 
allExternalEvents.get(0).getPayLoad().get("delinquent");
             log.info("Payload: {}", payLoad.toString());
 
             Assertions.assertNotNull(payLoad.get("delinquentPrincipal"));
@@ -106,6 +106,13 @@ public class CustomSnapshotEventIntegrationTest extends 
BaseLoanIntegrationTest
             Assertions.assertEquals(0.0, payLoad.get("delinquentFee"));
             Assertions.assertNotNull(payLoad.get("delinquentPenalty"));
             Assertions.assertEquals(0.0, payLoad.get("delinquentPenalty"));
+
+            payLoad = (Map<String, Object>) 
allExternalEvents.get(0).getPayLoad().get("summary");
+            log.info("Payload: {}", payLoad.toString());
+            
Assertions.assertNotNull(payLoad.get("totalInterestPaymentWaiver"));
+            Assertions.assertEquals(0.0, 
payLoad.get("totalInterestPaymentWaiver"));
+            
Assertions.assertNotNull(payLoad.get("totalRepaymentTransactionReversed"));
+            Assertions.assertEquals(0.0, 
payLoad.get("totalRepaymentTransactionReversed"));
         });
     }
 

Reply via email to