diff options
author | Dan Timoney <dtimoney@att.com> | 2019-01-29 20:04:10 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@onap.org> | 2019-01-29 20:04:10 +0000 |
commit | 078668224699d4d31df9f57dddb91cb4d66d575c (patch) | |
tree | 087cf129a64654a6f913453a7d6cfd74bd525fc2 /ms | |
parent | 7ba0409c8305793479376034a44ff34997ac7b14 (diff) | |
parent | 9512e9a04159b22c71fe3854ab6077f4200ef52a (diff) |
Merge "Added test cases to AaiServiceImpl.java"
Diffstat (limited to 'ms')
-rw-r--r-- | ms/neng/src/test/java/org/onap/ccsdk/apps/ms/neng/service/extinf/impl/AaiServiceImplTest.java | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/ms/neng/src/test/java/org/onap/ccsdk/apps/ms/neng/service/extinf/impl/AaiServiceImplTest.java b/ms/neng/src/test/java/org/onap/ccsdk/apps/ms/neng/service/extinf/impl/AaiServiceImplTest.java index 8507bf65..f7d0bc28 100644 --- a/ms/neng/src/test/java/org/onap/ccsdk/apps/ms/neng/service/extinf/impl/AaiServiceImplTest.java +++ b/ms/neng/src/test/java/org/onap/ccsdk/apps/ms/neng/service/extinf/impl/AaiServiceImplTest.java @@ -48,14 +48,18 @@ public class AaiServiceImplTest { AaiResponse aaiResponse = aaiServiceImpl.buildResponse(true); Assert.assertEquals(aaiResponse.isRecFound(), true); } - + @Test(expected= Exception.class) public void testValidate() throws Exception { AaiProps aaiProps=new AaiProps(); aaiProps.setUriBase("http://"); aaiServiceImpl.setAaiProps(aaiProps); aaiServiceImpl.setRestTemplate(new RestTemplate()); - aaiServiceImpl.validate("testUrl/","testName"); - + Assert.assertTrue(aaiServiceImpl.validate("testUrl/","testName")); + } + @Test(expected= Exception.class) + public void testGetRestTemplate_Null() throws Exception { + aaiServiceImpl.setRestTemplate(null); + Assert.assertNotNull(aaiServiceImpl.getRestTemplate()); } } |