diff options
Diffstat (limited to 'ms/neng/src/test')
-rw-r--r-- | ms/neng/src/test/java/org/onap/ccsdk/apps/ms/neng/service/extinf/impl/AaiServiceImplTest.java | 14 |
1 files changed, 12 insertions, 2 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 b25de210..8507bf65 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 @@ -4,8 +4,6 @@ * ================================================================================ * Copyright (C) 2018 IBM. * ================================================================================ - * Modifications Copyright (C) 2018 IBM. - * ================================================================================ * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at @@ -26,7 +24,9 @@ import org.junit.Assert; import org.junit.Before; import org.junit.Test; import org.onap.ccsdk.apps.ms.neng.core.resource.model.AaiResponse; +import org.onap.ccsdk.apps.ms.neng.extinf.props.AaiProps; import org.springframework.boot.web.client.RestTemplateBuilder; +import org.springframework.web.client.RestTemplate; public class AaiServiceImplTest { private AaiServiceImpl aaiServiceImpl; @@ -48,4 +48,14 @@ 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"); + + } } |