summaryrefslogtreecommitdiffstats
path: root/ms/sliboot/src/test
diff options
context:
space:
mode:
authorDan Timoney <dtimoney@att.com>2020-06-05 15:46:39 -0400
committerKAPIL SINGAL <ks220y@att.com>2020-06-09 14:24:12 +0000
commit31172d602ff8bce4b4680c3a2da58b6db2e8d9f0 (patch)
treebf66bc083d8f1a46c17132c990c7e725e828514d /ms/sliboot/src/test
parentc2fac23347ee5dd3f8b6e3180a0206eb979b965e (diff)
Refactor sliapi springboot
Moved sli-api springboot microservice from ccsdk/sli/core to ccsdk/apps Change-Id: Ibecae568cf90b71575403052111e7be9ff543376 Issue-ID: CCSDK-2096 Signed-off-by: Dan Timoney <dtimoney@att.com>
Diffstat (limited to 'ms/sliboot/src/test')
-rw-r--r--ms/sliboot/src/test/java/org/onap/ccsdk/apps/ms/sliboot/AppTest.java39
-rw-r--r--ms/sliboot/src/test/java/org/onap/ccsdk/apps/ms/sliboot/RestconfApiControllerTest.java172
-rwxr-xr-xms/sliboot/src/test/resources/DEMO_DEMO.xml35
-rw-r--r--ms/sliboot/src/test/resources/application.properties18
-rw-r--r--ms/sliboot/src/test/resources/graph.versions3
-rw-r--r--ms/sliboot/src/test/resources/log4j2.properties160
-rw-r--r--ms/sliboot/src/test/resources/shiro-users.properties3
-rw-r--r--ms/sliboot/src/test/resources/sli_healthcheck.xml27
-rw-r--r--ms/sliboot/src/test/resources/sli_vlbcheck.xml27
-rw-r--r--ms/sliboot/src/test/resources/svclogic.properties29
10 files changed, 513 insertions, 0 deletions
diff --git a/ms/sliboot/src/test/java/org/onap/ccsdk/apps/ms/sliboot/AppTest.java b/ms/sliboot/src/test/java/org/onap/ccsdk/apps/ms/sliboot/AppTest.java
new file mode 100644
index 00000000..abca6d94
--- /dev/null
+++ b/ms/sliboot/src/test/java/org/onap/ccsdk/apps/ms/sliboot/AppTest.java
@@ -0,0 +1,39 @@
+package org.onap.ccsdk.apps.ms.sliboot;
+
+import org.apache.shiro.realm.Realm;
+import org.apache.shiro.realm.text.PropertiesRealm;
+import org.apache.shiro.spring.web.config.ShiroFilterChainDefinition;
+import org.junit.Before;
+import org.junit.Test;
+
+import java.util.Map;
+
+import static org.junit.Assert.*;
+
+public class AppTest {
+
+ App app;
+
+ @Before
+ public void setUp() throws Exception {
+ app = new App();
+ System.setProperty("serviceLogicProperties", "src/test/resources/svclogic.properties");
+ }
+
+ @Test
+ public void realm() {
+ Realm realm = app.realm();
+ assertTrue(realm instanceof PropertiesRealm);
+
+
+ }
+
+ @Test
+ public void shiroFilterChainDefinition() {
+ ShiroFilterChainDefinition chainDefinition = app.shiroFilterChainDefinition();
+ Map<String, String> chainMap = chainDefinition.getFilterChainMap();
+ assertEquals("anon", chainMap.get("/**"));
+
+
+ }
+} \ No newline at end of file
diff --git a/ms/sliboot/src/test/java/org/onap/ccsdk/apps/ms/sliboot/RestconfApiControllerTest.java b/ms/sliboot/src/test/java/org/onap/ccsdk/apps/ms/sliboot/RestconfApiControllerTest.java
new file mode 100644
index 00000000..4a7a7ec8
--- /dev/null
+++ b/ms/sliboot/src/test/java/org/onap/ccsdk/apps/ms/sliboot/RestconfApiControllerTest.java
@@ -0,0 +1,172 @@
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP - CCSDK
+ * ================================================================================
+ * Copyright (C) 2020 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * 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
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.onap.ccsdk.apps.ms.sliboot;
+
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.onap.ccsdk.apps.ms.sliboot.swagger.model.*;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.boot.test.autoconfigure.web.servlet.AutoConfigureMockMvc;
+import org.springframework.boot.test.context.SpringBootTest;
+import org.springframework.http.MediaType;
+import org.springframework.test.context.junit4.SpringRunner;
+import org.springframework.test.web.servlet.MockMvc;
+import org.springframework.test.web.servlet.MvcResult;
+import org.springframework.test.web.servlet.request.MockMvcRequestBuilders;
+import com.fasterxml.jackson.core.JsonProcessingException;
+import com.fasterxml.jackson.databind.ObjectMapper;
+
+import java.util.List;
+
+import static org.junit.Assert.*;
+
+@RunWith(SpringRunner.class)
+@SpringBootTest
+@AutoConfigureMockMvc
+public class RestconfApiControllerTest {
+
+ private static final Logger log = LoggerFactory.getLogger(RestconfApiControllerTest.class);
+
+ @Autowired
+ private MockMvc mvc;
+
+ @Test
+ public void testHealthcheck() throws Exception {
+ String url = "/operations/SLI-API:healthcheck/";
+
+ MvcResult mvcResult =
+ mvc.perform(MockMvcRequestBuilders.post(url).contentType(MediaType.APPLICATION_JSON_VALUE).content(""))
+ .andReturn();
+
+ assertEquals(200, mvcResult.getResponse().getStatus());
+ }
+
+ @Test
+ public void testVlbcheck() throws Exception {
+ String url = "/operations/SLI-API:vlbcheck/";
+
+ MvcResult mvcResult =
+ mvc.perform(MockMvcRequestBuilders.post(url).contentType(MediaType.APPLICATION_JSON_VALUE).content(""))
+ .andReturn();
+
+ assertEquals(200, mvcResult.getResponse().getStatus());
+ }
+
+ @Test
+ public void testExecuteHealthcheck() throws Exception {
+ String url = "/operations/SLI-API:execute-graph/";
+
+ SliApiExecutegraphInput executeGraphData = new SliApiExecutegraphInput();
+ SliApiExecutegraphInputBodyparam executeGraphInput = new SliApiExecutegraphInputBodyparam();
+
+ executeGraphData.setModuleName("sli");
+ executeGraphData.setRpcName("healthcheck");
+ executeGraphData.setMode(SliApiModeEnumeration.SYNC);
+ executeGraphInput.setInput(executeGraphData);
+
+ String jsonString = mapToJson(executeGraphInput);
+ log.error("jsonString is {}", jsonString);
+
+ MvcResult mvcResult =
+ mvc.perform(MockMvcRequestBuilders.post(url).contentType(MediaType.APPLICATION_JSON_VALUE).content(jsonString))
+ .andReturn();
+
+ assertEquals(200, mvcResult.getResponse().getStatus());
+
+ }
+
+ @Test
+ public void testExecuteMissingDg() throws Exception {
+ String url = "/operations/SLI-API:execute-graph/";
+
+ SliApiExecutegraphInputBodyparam executeGraphInput = new SliApiExecutegraphInputBodyparam();
+ SliApiExecutegraphInput executeGraphData = new SliApiExecutegraphInput();
+
+ executeGraphData.setModuleName("sli");
+ executeGraphData.setRpcName("noSuchRPC");
+ executeGraphData.setMode(SliApiModeEnumeration.SYNC);
+ executeGraphInput.setInput(executeGraphData);
+
+ String jsonString = mapToJson(executeGraphInput);
+
+ log.error("jsonString is {}", jsonString);
+
+ MvcResult mvcResult =
+ mvc.perform(MockMvcRequestBuilders.post(url).contentType(MediaType.APPLICATION_JSON_VALUE).content(jsonString))
+ .andReturn();
+
+ assertEquals(401, mvcResult.getResponse().getStatus());
+
+ }
+
+ @Test
+ public void testTestResultAdd() throws Exception {
+ String url = "/config/SLI-API:test-results/";
+
+ MvcResult mvcResult = mvc.perform(MockMvcRequestBuilders.get(url).contentType(MediaType.APPLICATION_JSON_VALUE)).andReturn();
+
+ assertEquals(200, mvcResult.getResponse().getStatus());
+
+ // Delete any existing content before testing insert
+ mvcResult = mvc.perform(MockMvcRequestBuilders.delete(url).contentType(MediaType.APPLICATION_JSON)).andReturn();
+ assertEquals(200, mvcResult.getResponse().getStatus());
+
+ String jsonString = "{\n" +
+ " \"test-result\" : [\n" +
+ " {\n" +
+ " \"test-identifier\" : \"test-1\",\n" +
+ " \"results\" : [\"test result 1\"]\n" +
+ " }\n" +
+ " ]\n" +
+ "}";
+ mvcResult = mvc.perform(MockMvcRequestBuilders.post(url).contentType(MediaType.APPLICATION_JSON_VALUE).accept(MediaType.APPLICATION_JSON_VALUE).content(jsonString))
+ .andReturn();
+ assertEquals(200, mvcResult.getResponse().getStatus());
+
+ mvcResult = mvc.perform(MockMvcRequestBuilders.get(url).contentType(MediaType.APPLICATION_JSON)).andReturn();
+ assertEquals(200, mvcResult.getResponse().getStatus());
+
+ ObjectMapper objectMapper = new ObjectMapper();
+ SliApiTestResults testResults = objectMapper.readValue(mvcResult.getResponse().getContentAsString(), SliApiTestResults.class);
+ assertNotNull(testResults);
+ List<SliApiTestresultsTestResult> testResult = testResults.getTestResult();
+ assertNotNull(testResult);
+ assertFalse(testResult.isEmpty());
+ assertEquals(1, testResult.size());
+ SliApiTestresultsTestResult theResult = testResult.get(0);
+ assertEquals("test-1", theResult.getTestIdentifier());
+ assertEquals("test result 1", theResult.getResults().get(0));
+
+ }
+
+ private String mapToJson(Object obj) throws JsonProcessingException {
+ ObjectMapper objectMapper = new ObjectMapper();
+ return objectMapper.writeValueAsString(obj);
+ }
+
+ private SliApiResponseFields respFromJson(String jsonString) throws JsonProcessingException {
+ ObjectMapper objectMapper = new ObjectMapper();
+ return (objectMapper.readValue(jsonString, SliApiResponseFields.class));
+ }
+
+}
diff --git a/ms/sliboot/src/test/resources/DEMO_DEMO.xml b/ms/sliboot/src/test/resources/DEMO_DEMO.xml
new file mode 100755
index 00000000..1b304f18
--- /dev/null
+++ b/ms/sliboot/src/test/resources/DEMO_DEMO.xml
@@ -0,0 +1,35 @@
+<service-logic
+ xmlns='http://www.onap.org/sdnc/svclogic'
+ xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:schemaLocation='http://www.onap.org/sdnc/svclogic ./svclogic.xsd' module='DEMO' version='1'>
+ <method rpc='DEMO' mode='sync'>
+ <block>
+ <record plugin="org.onap.ccsdk.sli.core.sli.recording.Slf4jRecorder">
+ <parameter name="logger" value="message-log" />
+ <parameter name="level" value="error" />
+ <parameter name="field1" value="Slf4jRecorder must be working!" />
+ </record>
+ <execute plugin="org.onap.ccsdk.sli.core.slipluginutils.SliPluginUtils" method="generateUUID">
+ <parameter name="ctx-destination" value="requestID" />
+ </execute>
+ <execute plugin="org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils" method="contains" emitsOutcome='true' >
+ <parameter name="source" value="TEAM" />
+ <parameter name="target" value="I" />
+ </execute>
+ <execute plugin="org.onap.ccsdk.sli.plugins.prop.PropertiesNode" method="readProperties" >
+ <parameter name="fileName" value="%SDNC_CONFIG_DIR%/aaf.properties" />
+ <parameter name="contextPrefix" value="tmp.props" />
+ </execute>
+ <execute plugin="org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode" method="sendRequest">
+ <parameter name="restapiUrl" value="http://127.0.0.1:8080/restconf/config/SLI-API:test-results/"/>
+ <parameter name="restapiUser" value="admin"/>
+ <parameter name="restapiPassword" value="test"/>
+ <parameter name="format" value="json" />
+ <parameter name="httpMethod" value="get" />
+ <parameter name="responsePrefix" value="restapi-result" />
+ </execute>
+ <return status='success'>
+ <parameter name='' value='' />
+ </return>
+ </block>
+ </method>
+</service-logic> \ No newline at end of file
diff --git a/ms/sliboot/src/test/resources/application.properties b/ms/sliboot/src/test/resources/application.properties
new file mode 100644
index 00000000..58bf3cd8
--- /dev/null
+++ b/ms/sliboot/src/test/resources/application.properties
@@ -0,0 +1,18 @@
+springfox.documentation.swagger.v2.path=/api-docs
+server.servlet.context-path=/restconf
+server.port=8080
+spring.jackson.date-format=org.onap.ccsdk.apps.ms.sliboot.swagger.RFC3339DateFormat
+spring.jackson.serialization.WRITE_DATES_AS_TIMESTAMPS=false
+logging.level.com.att=TRACE
+logging.level.org.onap=TRACE
+spring.datasource.url=jdbc:derby:memory:sdnctl;create=true
+spring.datasource.username=sli
+spring.datasource.password=abc123
+spring.datasource.driver-class-name=org.apache.derby.jdbc.EmbeddedDriver
+spring.datasource.testWhileIdle=true
+spring.datasource.validationQuery=SELECT 1
+spring.jpa.show-sql=true
+spring.jpa.hibernate.ddl-auto=update
+spring.jpa.hibernate.naming.implicit-strategy=org.hibernate.boot.model.naming.ImplicitNamingStrategyLegacyHbmImpl
+spring.jpa.hibernate.naming.physical-strategy=org.hibernate.boot.model.naming.PhysicalNamingStrategyStandardImpl
+spring.jpa.database=derby \ No newline at end of file
diff --git a/ms/sliboot/src/test/resources/graph.versions b/ms/sliboot/src/test/resources/graph.versions
new file mode 100644
index 00000000..d21278aa
--- /dev/null
+++ b/ms/sliboot/src/test/resources/graph.versions
@@ -0,0 +1,3 @@
+sli healthcheck 0.7.0 sync
+sli vlbcheck 0.7.0 sync
+DEMO DEMO 1 sync
diff --git a/ms/sliboot/src/test/resources/log4j2.properties b/ms/sliboot/src/test/resources/log4j2.properties
new file mode 100644
index 00000000..40d18d15
--- /dev/null
+++ b/ms/sliboot/src/test/resources/log4j2.properties
@@ -0,0 +1,160 @@
+ #-
+ # ============LICENSE_START=======================================================
+ # ONAP - CCSDK
+ # ================================================================================
+ # Copyright (C) 2020 AT&T Intellectual Property. All rights reserved.
+ # ================================================================================
+ # 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
+ #
+ # http://www.apache.org/licenses/LICENSE-2.0
+ #
+ # Unless required by applicable law or agreed to in writing, software
+ # distributed under the License is distributed on an "AS IS" BASIS,
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ # See the License for the specific language governing permissions and
+ # limitations under the License.
+ # ============LICENSE_END=========================================================
+ #
+
+property.logDir = ${sys:LOG_PATH:-./target}
+
+property.pattern = %d{ISO8601} | %-5p | %-16t | %-32c{1} | %X{currentGraph} - %X{nodeId} | %m%n
+
+#default mdc values
+property.ServiceName = INTERNAL
+property.ErrorCode = 900
+property.ErrorDesc = UnknownError
+
+rootLogger.level = INFO
+rootLogger.appenderRef.AppFile.ref = AppFile
+rootLogger.appenderRef.Console.ref = Console
+rootLogger.appenderRef.DebugFile.ref = DebugFile
+rootLogger.appenderRef.ErrorFile.ref = ErrorFile
+rootLogger.appenderRef.Console.filter.threshold.type = ThresholdFilter
+rootLogger.appenderRef.Console.filter.threshold.level = DEBUG
+
+appender.console.type = Console
+appender.console.name = Console
+appender.console.layout.type = PatternLayout
+appender.console.layout.pattern = ${pattern}
+
+appender.app.type = RollingRandomAccessFile
+appender.app.name = AppFile
+appender.app.fileName = ${logDir}/app.log
+appender.app.filePattern = ${logDir}/app.log.%i
+appender.app.immediateFlush = true
+appender.app.append = true
+appender.app.layout.type = PatternLayout
+appender.app.layout.pattern = ${pattern}
+appender.app.policies.type = Policies
+appender.app.policies.size.type = SizeBasedTriggeringPolicy
+appender.app.policies.size.size = 10MB
+appender.app.strategy.type = DefaultRolloverStrategy
+appender.app.strategy.max = 100
+appender.app.strategy.fileIndex = min
+
+appender.debug.type = RollingRandomAccessFile
+appender.debug.name = DebugFile
+appender.debug.fileName = ${logDir}/debug.log
+appender.debug.filePattern = ${logDir}/debug.log.%i
+appender.debug.immediateFlush = true
+appender.debug.append = true
+appender.debug.layout.type = PatternLayout
+appender.debug.layout.pattern = %d{yyyy-MM-dd'T'HH:mm:ss.SSSXXX}|%X{RequestID}|%-16.16t|%-5.5p|%-32.32c{1}|%X{currentGraph} - %X{nodeId}|%m%n
+appender.debug.policies.type = Policies
+appender.debug.policies.size.type = SizeBasedTriggeringPolicy
+appender.debug.policies.size.size = 10MB
+appender.debug.strategy.type = DefaultRolloverStrategy
+appender.debug.strategy.max = 200
+appender.debug.strategy.fileIndex = min
+
+appender.error.type = RollingRandomAccessFile
+appender.error.name = ErrorFile
+appender.error.fileName = ${logDir}/error.log
+appender.error.filePattern = ${logDir}/error.log.%i
+appender.error.immediateFlush = true
+appender.error.append = true
+appender.error.layout.type = PatternLayout
+appender.error.layout.pattern = %d{yyyy-MM-dd'T'HH:mm:ss.SSSXXX}|%X{RequestID}|%-16.16t|$${ctx:ServiceName}|%X{PartnerName}|%X{TargetEntity}|%X{TargetServiceName}|%p|$${ctx:ErrorCode}|$${ctx:ErrorDesc}|%m%n
+
+appender.error.policies.type = Policies
+appender.error.policies.size.type = SizeBasedTriggeringPolicy
+appender.error.policies.size.size = 10MB
+appender.error.strategy.type = DefaultRolloverStrategy
+appender.error.strategy.max = 100
+appender.error.strategy.fileIndex = min
+appender.error.filter.threshold.type = ThresholdFilter
+appender.error.filter.threshold.level = WARN
+
+appender.metric.type = RollingRandomAccessFile
+appender.metric.name = MetricFile
+appender.metric.fileName = ${logDir}/metric.log
+appender.metric.filePattern = ${logDir}/metric.log.%i
+appender.metric.immediateFlush = true
+appender.metric.append = true
+appender.metric.layout.type = PatternLayout
+appender.metric.layout.pattern=%X{InvokeTimestamp}|%X{LogTimestamp}|%X{RequestID}|%X{ServiceInstanceID}|%-16.16t|%X{ServerFQDN}|%X{ServiceName}|%X{PartnerName}|%X{TargetEntity}|%X{TargetServiceName}|%X{StatusCode}|%X{ResponseCode}|%X{ResponseDesc}|%X{InstanceID}|%p|%X{Severity}|192.168.23.111|%X{ElapsedTime}|${hostName}|%X{ClientIPAddress}|%C{1}|||%X{TargetElement}|%markerSimpleName|%X|%X{currentGraph} - %X{nodeId}||%m%n
+appender.metric.policies.type = Policies
+appender.metric.policies.size.type = SizeBasedTriggeringPolicy
+appender.metric.policies.size.size = 10MB
+appender.metric.strategy.type = DefaultRolloverStrategy
+appender.metric.strategy.max = 100
+appender.metric.strategy.fileIndex = min
+
+appender.audit.type = RollingRandomAccessFile
+appender.audit.name = AuditFile
+appender.audit.fileName = ${logDir}/audit.log
+appender.audit.filePattern = ${logDir}/audit.log.%i
+appender.audit.immediateFlush = true
+appender.audit.append = true
+appender.audit.layout.type = PatternLayout
+appender.audit.layout.pattern=%X{EntryTimestamp}|%X{LogTimestamp}|%X{RequestID}|%X{ServiceInstanceID}|%-16.16t|%X{ServerFQDN}|%X{ServiceName}|%X{PartnerName}|%X{StatusCode}|%X{ResponseCode}|%X{ResponseDesc}|%X{InstanceID}|INFO|%X{Severity}|192.168.23.111|%X{ElapsedTime}|${hostName}|%X{ClientIPAddress}|%C{1}|%X{AUDIT-Unused}|%X{AUDIT-ProcessKey}|%markerSimpleName|%X|||%m%n
+appender.audit.policies.type = Policies
+appender.audit.policies.size.type = SizeBasedTriggeringPolicy
+appender.audit.policies.size.size = 10MB
+appender.audit.strategy.type = DefaultRolloverStrategy
+appender.audit.strategy.max = 200
+appender.audit.strategy.fileIndex = min
+
+appender.rr.name = RequestResponseFile
+appender.rr.type = RollingRandomAccessFile
+appender.rr.fileName = ${logDir}/request-response.log
+appender.rr.filePattern = ${logDir}/request-response.log.%i
+appender.rr.immediateFlush = true
+appender.rr.append = true
+appender.rr.layout.type = PatternLayout
+appender.rr.layout.pattern = %d{yyyy-MM-dd'T'HH:mm:ss.SSSXXX}|%X{RequestID}|%X{PartnerName}|%m%n
+appender.rr.policies.type = Policies
+appender.rr.policies.size.type = SizeBasedTriggeringPolicy
+appender.rr.policies.size.size = 10MB
+appender.rr.strategy.type = DefaultRolloverStrategy
+appender.rr.strategy.max = 100
+appender.rr.strategy.fileIndex = min
+
+logger.metric.name = org.onap.ccsdk.sli.core.filters.metric
+logger.metric.level = INFO
+logger.metric.additivity = false
+logger.metric.appenderRef.MetricFile.ref = MetricFile
+
+logger.metric2.name = org.onap.logging.filter.base.AbstractMetricLogFilter
+logger.metric2.level = INFO
+logger.metric2.additivity = false
+logger.metric2.appenderRef.MetricFile.ref = MetricFile
+
+logger.audit.name = org.onap.logging.filter.base.AbstractAuditLogFilter
+logger.audit.level = INFO
+logger.audit.additivity = false
+logger.audit.appenderRef.AuditFile.ref = AuditFile
+
+logger.rr.name = org.onap.logging.filter.base.PayloadLoggingServletFilter
+logger.rr.level = INFO
+logger.rr.additivity = false
+logger.rr.appenderRef.RequestResponseFile.ref = RequestResponseFile
+
+logger.ccsdk.name = org.onap.ccsdk
+logger.ccsdk.level = DEBUG
+
+logger.onaplogging.name = org.onap.logging
+logger.onaplogging.level = DEBUG \ No newline at end of file
diff --git a/ms/sliboot/src/test/resources/shiro-users.properties b/ms/sliboot/src/test/resources/shiro-users.properties
new file mode 100644
index 00000000..df4b1ae7
--- /dev/null
+++ b/ms/sliboot/src/test/resources/shiro-users.properties
@@ -0,0 +1,3 @@
+user.admin = Kp8bJ4SXszM0WXlhak3eHlcse2gAw84vaoGGmJvUy2U,service
+role.service = odl-api:*
+
diff --git a/ms/sliboot/src/test/resources/sli_healthcheck.xml b/ms/sliboot/src/test/resources/sli_healthcheck.xml
new file mode 100644
index 00000000..bc8e2f70
--- /dev/null
+++ b/ms/sliboot/src/test/resources/sli_healthcheck.xml
@@ -0,0 +1,27 @@
+<!--
+ ============LICENSE_START=======================================================
+ openECOMP : SDN-C
+ ================================================================================
+ Copyright (C) 2017 AT&T Intellectual Property. All rights
+ reserved.
+ ================================================================================
+ 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
+ http://www.apache.org/licenses/LICENSE-2.0
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ ============LICENSE_END=========================================================
+ -->
+
+<service-logic xmlns="http://www.onap.org/sdnc/svclogic"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://www.onap.org/sdnc/svclogic ./svclogic.xsd" module='sli' version='0.7.0'><method rpc='healthcheck' mode='sync'>
+<set>
+<parameter name='error-code' value='200' />
+<parameter name='error-message' value='SDN-C is healthy'/>
+<parameter name='ack-final' value='Y'/>
+</set></method></service-logic>
diff --git a/ms/sliboot/src/test/resources/sli_vlbcheck.xml b/ms/sliboot/src/test/resources/sli_vlbcheck.xml
new file mode 100644
index 00000000..820a85c1
--- /dev/null
+++ b/ms/sliboot/src/test/resources/sli_vlbcheck.xml
@@ -0,0 +1,27 @@
+<!--
+ ============LICENSE_START=======================================================
+ openECOMP : SDN-C
+ ================================================================================
+ Copyright (C) 2017 AT&T Intellectual Property. All rights
+ reserved.
+ ================================================================================
+ 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
+ http://www.apache.org/licenses/LICENSE-2.0
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ ============LICENSE_END=========================================================
+ -->
+
+<service-logic xmlns="http://www.onap.org/sdnc/svclogic"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://www.onap.org/sdnc/svclogic ./svclogic.xsd" module='sli' version='0.7.0'><method rpc='vlbcheck' mode='sync'>
+<set>
+<parameter name='error-code' value='200' />
+<parameter name='error-message' value='SDN-C is healthy'/>
+<parameter name='ack-final' value='Y'/>
+</set></method></service-logic>
diff --git a/ms/sliboot/src/test/resources/svclogic.properties b/ms/sliboot/src/test/resources/svclogic.properties
new file mode 100644
index 00000000..1d90ab9b
--- /dev/null
+++ b/ms/sliboot/src/test/resources/svclogic.properties
@@ -0,0 +1,29 @@
+###
+# ============LICENSE_START=======================================================
+# ONAP : CCSDK
+# ================================================================================
+# Copyright (C) 2017 AT&T Intellectual Property. All rights
+# reserved.
+# ================================================================================
+# 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
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+# ============LICENSE_END=========================================================
+###
+
+org.onap.ccsdk.sli.dbtype = jdbc
+org.onap.ccsdk.sli.jdbc.url=jdbc:derby:memory:sdnctl;create=true
+org.onap.ccsdk.sli.jdbc.driver=org.apache.derby.jdbc.EmbeddedDriver
+org.onap.ccsdk.sli.jdbc.database = sdnctl
+org.onap.ccsdk.sli.jdbc.user = test
+org.onap.ccsdk.sli.jdbc.password = test
+
+sliapi.serviceLogicDirectory=/opt/onap/sdnc/svclogic/graphs