thesmallstar commented on a change in pull request #1100:
URL: https://github.com/apache/fineract/pull/1100#discussion_r444103649



##########
File path: 
fineract-provider/src/integrationTest/java/org/apache/fineract/integrationtests/common/AuditHelper.java
##########
@@ -0,0 +1,49 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.fineract.integrationtests.common;
+
+import static org.junit.jupiter.api.Assertions.assertEquals;
+
+import io.restassured.specification.RequestSpecification;
+import io.restassured.specification.ResponseSpecification;
+import java.util.ArrayList;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ *
+ * @author Manthan Surkar
+ *
+ */
+
+public class AuditHelper {
+
+    private static final Logger LOG = 
LoggerFactory.getLogger(AuditHelper.class);
+    private static final String AUDIT_BASE_URL = 
"/fineract-provider/api/v1/audits?" + Utils.TENANT_IDENTIFIER;
+
+    public static void verifyAuditCreatedOnServer(final RequestSpecification 
requestSpec, final ResponseSpecification responseSpec,
+            final Integer resourceId, final String actionName, final String 
entityName) {
+        LOG.info("------------------------------CHECK IF AUDIT 
CREATED------------------------------------\n");
+        final String AUDIT_URL = "/fineract-provider/api/v1/audits/?" + 
"entityName=" + entityName + "&resourceId=" + resourceId
+                + "&actionName=" + actionName + "&" + Utils.TENANT_IDENTIFIER;
+        final ArrayList<Integer> responseAuditIDs = 
Utils.performServerGet(requestSpec, responseSpec, AUDIT_URL, "id");

Review comment:
       understood!




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

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


Reply via email to