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


##########
fineract-e2e-tests-core/src/test/java/org/apache/fineract/test/stepdef/loan/WorkingCapitalLoanAccountStepDef.java:
##########
@@ -2009,6 +2009,31 @@ public void 
adminAddWorkingCapitalPeriodPaymentRate(String periodPaymentRate) {
         checkWorkingCapitalPeriodPaymentRate(loanId, periodPaymentRate);
     }
 
+    @When("Admin update Working Capital period payment rate with {string} 
value effective from {string}")
+    public void adminAddWorkingCapitalPeriodPaymentRateEffectiveFrom(final 
String periodPaymentRate, final String effectiveDate) {
+        final PostWorkingCapitalLoansResponse loanResponse = 
testContext().get(TestContextKey.LOAN_CREATE_RESPONSE);
+        long loanId = loanResponse.getLoanId();
+
+        PutWorkingCapitalLoansLoanIdRateRequest rateChangeRequest = 
workingCapitalLoanRequestFactory
+                
.defaultWorkingCapitalLoanUpdateRateRequest().periodPaymentRate(new 
BigDecimal(periodPaymentRate))
+                .effectiveDate(effectiveDate);
+
+        final CommandProcessingResult rateChangeResponse = ok(
+                () -> 
fineractClient.workingCapitalLoans().updateWorkingCapitalLoanRateById(loanId, 
rateChangeRequest));
+
+        testContext().set(TestContextKey.WORKING_CAPITAL_LOAN_RATE_CHANGE_ID, 
rateChangeResponse.getResourceId());
+        assertThat(rateChangeResponse.getChanges()).isNotNull();

Review Comment:
   We have a list for the payment rate changes which can be fetched and checked



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