diff options
Diffstat (limited to 'mso-api-handlers/mso-requests-db/src/test/java/org')
-rw-r--r-- | mso-api-handlers/mso-requests-db/src/test/java/org/onap/so/db/request/client/RequestDbClientTest.java | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/mso-api-handlers/mso-requests-db/src/test/java/org/onap/so/db/request/client/RequestDbClientTest.java b/mso-api-handlers/mso-requests-db/src/test/java/org/onap/so/db/request/client/RequestDbClientTest.java index fdbc04acb4..fff6ad1013 100644 --- a/mso-api-handlers/mso-requests-db/src/test/java/org/onap/so/db/request/client/RequestDbClientTest.java +++ b/mso-api-handlers/mso-requests-db/src/test/java/org/onap/so/db/request/client/RequestDbClientTest.java @@ -10,8 +10,10 @@ import org.mockito.InjectMocks; import org.mockito.Mock; import org.mockito.Mockito; import org.mockito.junit.MockitoJUnitRunner; +import org.onap.so.db.request.beans.InfraActiveRequests; import org.onap.so.db.request.beans.RequestProcessingData; import org.springframework.http.HttpEntity; +import org.springframework.http.HttpMethod; import org.springframework.web.client.RestTemplate; @@ -32,4 +34,14 @@ public class RequestDbClientTest { requestsDbClient.updateRequestProcessingData(requestProcessingData); Mockito.verify(restTemplate, times(1)).put(eq(uri), isA(HttpEntity.class)); } + + @Test + public void updateInfraActiveRequestsTest() { + InfraActiveRequests request = new InfraActiveRequests(); + request.setRequestId("1"); + URI uri = URI.create("/infraActiveRequests/1"); + requestsDbClient.patchInfraActiveRequests(request); + Mockito.verify(restTemplate, times(1)).exchange(eq(uri), eq(HttpMethod.PATCH), isA(HttpEntity.class), + eq(String.class)); + } } |