diff options
author | 2019-10-09 11:47:12 +0000 | |
---|---|---|
committer | 2019-10-09 11:47:12 +0000 | |
commit | 52ad94fa9c73e3edb96abf4dc99fa32c892ded5e (patch) | |
tree | 201dbcd8af17d5c4244dfe3c131f3f7ba0f9d67f /common/src/test | |
parent | 9c55b74f92bf4d4f017504f917b0bce617a523c8 (diff) | |
parent | fbf6300274558ffe323bf66bb5b23c72c350d3ee (diff) |
Merge "Improved error handling"
Diffstat (limited to 'common/src/test')
-rw-r--r-- | common/src/test/java/org/onap/so/rest/service/HttpRestServiceProviderImplTest.java | 5 |
1 files changed, 3 insertions, 2 deletions
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); } |