Search in sources :

Example 6 with AuditLogListQuery

use of eu.europa.ec.fisheries.schema.audit.search.v1.AuditLogListQuery in project UVMS-Docker by UnionVMS.

the class AuditRestIT method getListByQueryTest.

/**
 * Gets the config search fields test.
 *
 * @return the config search fields test
 * @throws Exception
 *             the exception
 */
@Test
public void getListByQueryTest() throws Exception {
    AuditLogListQuery auditLogListQuery = new AuditLogListQuery();
    ListPagination listPagination = new ListPagination();
    listPagination.setPage(BigInteger.valueOf(1));
    listPagination.setListSize(BigInteger.valueOf(25));
    auditLogListQuery.setPagination(listPagination);
    final HttpResponse response = Request.Post(getBaseUrl() + "audit/rest/audit/list").setHeader("Content-Type", "application/json").setHeader("Authorization", getValidJwtToken()).bodyByteArray(writeValueAsString(auditLogListQuery).getBytes()).execute().returnResponse();
    Map<String, Object> dataMap = checkSuccessResponseReturnMap(response);
}
Also used : AuditLogListQuery(eu.europa.ec.fisheries.schema.audit.search.v1.AuditLogListQuery) ListPagination(eu.europa.ec.fisheries.schema.audit.search.v1.ListPagination) HttpResponse(org.apache.http.HttpResponse) Test(org.junit.Test) AbstractRestServiceTest(eu.europa.ec.fisheries.uvms.docker.validation.common.AbstractRestServiceTest)

Aggregations

AuditLogListQuery (eu.europa.ec.fisheries.schema.audit.search.v1.AuditLogListQuery)5 ListCriteria (eu.europa.ec.fisheries.schema.audit.search.v1.ListCriteria)2 ListPagination (eu.europa.ec.fisheries.schema.audit.search.v1.ListPagination)2 AssetListCriteria (eu.europa.ec.fisheries.wsdl.asset.types.AssetListCriteria)2 AuditLogType (eu.europa.ec.fisheries.schema.audit.v1.AuditLogType)1 AbstractRestServiceTest (eu.europa.ec.fisheries.uvms.docker.validation.common.AbstractRestServiceTest)1 HttpResponse (org.apache.http.HttpResponse)1 Test (org.junit.Test)1