aboutsummaryrefslogtreecommitdiffstats
path: root/aai-schema-ingest/src
diff options
context:
space:
mode:
authorWilliam Reehil <william.reehil@att.com>2022-11-11 13:37:39 +0000
committerGerrit Code Review <gerrit@onap.org>2022-11-11 13:37:39 +0000
commit72b44a38290334c46a9dedc0be1dadcd08520515 (patch)
tree4ea0ae01f4dabf1b9781779b5fea790f9c2c03ba /aai-schema-ingest/src
parent131345b4ef18b8dc2c346c6af59f90f0d3fde431 (diff)
parent2c9ee21f2cf8fc230decfc48e3f652fe11862216 (diff)
Merge "Reduce the number of raw-type related warnings in aai-common"
Diffstat (limited to 'aai-schema-ingest/src')
-rw-r--r--aai-schema-ingest/src/test/java/org/onap/aai/restclient/MockRestClient.java14
-rw-r--r--aai-schema-ingest/src/test/java/org/onap/aai/restclient/SchemaRestClientTest.java2
2 files changed, 9 insertions, 7 deletions
diff --git a/aai-schema-ingest/src/test/java/org/onap/aai/restclient/MockRestClient.java b/aai-schema-ingest/src/test/java/org/onap/aai/restclient/MockRestClient.java
index 57988f0b..16889c7c 100644
--- a/aai-schema-ingest/src/test/java/org/onap/aai/restclient/MockRestClient.java
+++ b/aai-schema-ingest/src/test/java/org/onap/aai/restclient/MockRestClient.java
@@ -188,7 +188,7 @@ public class MockRestClient extends RestClient {
}
@Override
- public ResponseEntity execute(String uri, HttpMethod method, Map<String, String> headers, String body) {
+ public ResponseEntity<String> execute(String uri, HttpMethod method, Map<String, String> headers, String body) {
String url = "https://localhost:8447/aai/v14/" + uri;
@@ -224,16 +224,17 @@ public class MockRestClient extends RestClient {
headersMap.add("X-FromAppId", "JUNIT");
headersMap.add("X-TransactionId", "JUNIT");
- HttpEntity httpEntity = new HttpEntity(headers);
+ HttpEntity<String> httpEntity = new HttpEntity(headers);
- ResponseEntity responseEntity = restTemplate.exchange(url, HttpMethod.GET, httpEntity, String.class);
+ ResponseEntity<String> responseEntity = restTemplate.exchange(url, HttpMethod.GET, httpEntity, String.class);
// mockRestServiceServer.verify();
return responseEntity;
}
@Override
- public ResponseEntity executeResource(String uri, HttpMethod method, Map<String, String> headers, String body) {
+ public ResponseEntity<Resource> executeResource(String uri, HttpMethod method, Map<String, String> headers,
+ String body) {
String url = "https://localhost:8447/aai/v14/" + uri;
@@ -269,9 +270,10 @@ public class MockRestClient extends RestClient {
headersMap.add("X-FromAppId", "JUNIT");
headersMap.add("X-TransactionId", "JUNIT");
- HttpEntity httpEntity = new HttpEntity(headers);
+ HttpEntity<String> httpEntity = new HttpEntity(headers);
- ResponseEntity responseEntity = restTemplate.exchange(url, HttpMethod.GET, httpEntity, Resource.class);
+ ResponseEntity<Resource> responseEntity =
+ restTemplate.exchange(url, HttpMethod.GET, httpEntity, Resource.class);
// mockRestServiceServer.verify();
return responseEntity;
diff --git a/aai-schema-ingest/src/test/java/org/onap/aai/restclient/SchemaRestClientTest.java b/aai-schema-ingest/src/test/java/org/onap/aai/restclient/SchemaRestClientTest.java
index cbbc63d3..4b12936e 100644
--- a/aai-schema-ingest/src/test/java/org/onap/aai/restclient/SchemaRestClientTest.java
+++ b/aai-schema-ingest/src/test/java/org/onap/aai/restclient/SchemaRestClientTest.java
@@ -50,7 +50,7 @@ public class SchemaRestClientTest {
@Test
public void testGetRequestToSchemaService() {
- ResponseEntity aaiResponse;
+ ResponseEntity<String> aaiResponse;
RestClient restClient = null;
restClient = restClientFactory.getRestClient(SCHEMA_SERVICE);