From fbf6300274558ffe323bf66bb5b23c72c350d3ee Mon Sep 17 00:00:00 2001 From: MichaelMorris Date: Thu, 3 Oct 2019 17:45:05 +0100 Subject: Improved error handling Change-Id: Iac436f6a950bf61ac6321ef1d427a7bb14774e30 Issue-ID: SO-2395 Signed-off-by: MichaelMorris --- .../org/onap/so/rest/service/HttpRestServiceProviderImplTest.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'common/src/test/java/org') diff --git a/common/src/test/java/org/onap/so/rest/service/HttpRestServiceProviderImplTest.java b/common/src/test/java/org/onap/so/rest/service/HttpRestServiceProviderImplTest.java index 978c016dec..72bacdf2db 100644 --- a/common/src/test/java/org/onap/so/rest/service/HttpRestServiceProviderImplTest.java +++ b/common/src/test/java/org/onap/so/rest/service/HttpRestServiceProviderImplTest.java @@ -33,6 +33,7 @@ import org.junit.runner.RunWith; import org.mockito.Mock; import org.mockito.junit.MockitoJUnitRunner; import org.onap.so.rest.exceptions.InvalidRestRequestException; +import org.onap.so.rest.exceptions.HttpResouceNotFoundException; import org.onap.so.rest.exceptions.RestProcessingException; import org.springframework.http.HttpEntity; import org.springframework.http.HttpMethod; @@ -116,7 +117,7 @@ public class HttpRestServiceProviderImplTest { } - @Test(expected = InvalidRestRequestException.class) + @Test(expected = HttpResouceNotFoundException.class) public void test_get_ThrowsInvalidRestRequestExceptionifHttpClientErrorExceptionWithHttpStatusNotFoundHttpStatus() { assertGetErrorScenario(HttpStatus.NOT_FOUND); } @@ -239,7 +240,7 @@ public class HttpRestServiceProviderImplTest { } - @Test(expected = InvalidRestRequestException.class) + @Test(expected = HttpResouceNotFoundException.class) public void test_post_ThrowsInvalidRestRequestExceptionifHttpClientErrorExceptionWithHttpStatusNotFoundHttpStatus() { assertPostErrorScenario(HttpStatus.NOT_FOUND); } -- cgit 1.2.3-korg