adamsaghy commented on code in PR #6084:
URL: https://github.com/apache/fineract/pull/6084#discussion_r3587944042


##########
integration-tests/src/test/java/org/apache/fineract/integrationtests/LoanDownPaymentTransactionChargebackTest.java:
##########
@@ -64,20 +60,16 @@ public void loanDownPaymentTransactionChargebackTest() {
                     installment(250.0, false, "15 April 2023")//
             );
 
-            // make down payment
-            final PostLoansLoanIdTransactionsResponse downPaymentTransaction_1 
= loanTransactionHelper.makeLoanDownPayment(loanId,
-                    new PostLoansLoanIdTransactionsRequest().dateFormat("dd 
MMMM yyyy").transactionDate("01 March 2023").locale("en")
-                            .transactionAmount(250.0));
+            final PostLoansLoanIdTransactionsResponse downPaymentTransaction_1 
= makeLoanDownPayment(loanId,
+                    new 
PostLoansLoanIdTransactionsRequest().dateFormat(LoanTestData.DATETIME_PATTERN).transactionDate("01
 March 2023")
+                            
.locale(LoanTestData.LOCALE).transactionAmount(250.0));
             assertNotNull(downPaymentTransaction_1);
 
-            // chargeback down payment transaction
-            final Long chargebackTransactionId = 
loanTransactionHelper.applyChargebackTransaction(loanId.intValue(),
-                    downPaymentTransaction_1.getResourceId(), "50.00", 0, 
responseSpec);
+            final Long chargebackTransactionId = 
applyChargebackTransaction(loanId, downPaymentTransaction_1.getResourceId(), 
50.0, 1L);

Review Comment:
   `getPaymentTypeId(0)`? Sounds like a weird logic... why dont you load the 
required payment type by name if we are unsure about the id?



-- 
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