diff --git a/appc-client/client-lib/src/test/java/org/openecomp/appc/client/impl/core/ResponseManagerTest.java b/appc-client/client-lib/src/test/java/org/openecomp/appc/client/impl/core/ResponseManagerTest.java
new file mode 100644
index 0000000..d1720f0
--- /dev/null
+++ b/appc-client/client-lib/src/test/java/org/openecomp/appc/client/impl/core/ResponseManagerTest.java
@@ -0,0 +1,163 @@
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP : APPC
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Copyright (C) 2017 Amdocs
+ * =============================================================================
+ * 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.
+ * 
+ * ECOMP is a trademark and service mark of AT&T Intellectual Property.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.openecomp.appc.client.impl.core;
+
+import org.openecomp.appc.client.impl.core.AsyncRequestResponseHandler;
+import org.openecomp.appc.client.impl.core.CoreException;
+import org.openecomp.appc.client.impl.core.CoreManager;
+import org.openecomp.appc.client.impl.core.ICoreAsyncResponseHandler;
+import org.openecomp.appc.client.impl.core.MessageContext;
+import org.openecomp.appc.client.impl.protocol.AsyncProtocol;
+import org.openecomp.appc.client.impl.protocol.ProtocolException;
+import org.openecomp.appc.client.impl.protocol.RetrieveMessageCallback;
+import org.junit.Before;
+
+import java.util.Properties;
+import java.util.concurrent.ExecutorService;
+import java.util.concurrent.Executors;
+
+import static org.mockito.Mockito.mock;
+
+public class ResponseManagerTest {
+
+    private final ExecutorService executorService = Executors.newFixedThreadPool(10);
+    ICoreAsyncResponseHandler listener1 = new ListenerImpl();
+    ICoreAsyncResponseHandler listener2 = new SleeepListenerImpl();
+    ICoreAsyncResponseHandler listener3 = new ListenerImpl();
+    CoreManager coreManager = null;
+
+    public void initialize() throws CoreException {
+        Properties prop = new Properties();
+        prop.setProperty("client.pool.size", "10");
+        prop.setProperty("client.response.timeout", "7000");
+        coreManager = new ResponseManagerTest.CoreManagerTest(prop);
+    }
+
+    void asyncRequest(String request, ICoreAsyncResponseHandler businessCallback, String correlationId, String rpcName) throws CoreException {
+        AsyncRequestResponseHandler requestResponseHandler = new AsyncRequestResponseHandler(correlationId, businessCallback, coreManager);
+        requestResponseHandler.sendRequest(request, correlationId, rpcName);
+    }
+
+    public void simpleResponseTest() throws Exception {
+        System.out.println("simpleResponseTest");
+        asyncRequest("request 1", listener1,"vasia1", "test");
+        MessageContext msgCtx = new MessageContext();
+        msgCtx.setCorrelationID("vasia1");
+        msgCtx.setType("response");
+        coreManager.getProtocolCallback().onResponse("vasia1 response",msgCtx);
+        coreManager.getProtocolCallback().onResponse("vasia2 response",msgCtx);
+        Thread.sleep(10);
+    }
+
+    public void twoResponseTest() throws Exception {
+        System.out.println("twoResponseTest");
+        asyncRequest("twoResponseTest request 1", listener2,"vasia2", "test");
+        MessageContext msgCtx = new MessageContext();
+        msgCtx.setCorrelationID("vasia2");
+        msgCtx.setType("response");
+        coreManager.getProtocolCallback().onResponse("second of vasia2",msgCtx);
+        Thread.sleep(100);
+        asyncRequest("twoResponseTest request 2", listener1,"vasia1", "test");
+        MessageContext msgCtx2 = new MessageContext();
+        msgCtx2.setCorrelationID("vasia1");
+        msgCtx2.setType("response");
+        coreManager.getProtocolCallback().onResponse("first of vasia1",msgCtx2);
+        Thread.sleep(150);
+    }
+
+    public void threeResponseTest() throws Exception {
+        System.out.println("treeResponseTest");
+        asyncRequest("threeResponseTest request 2", listener1,"vasia4", "test");
+        asyncRequest("threeResponseTest request 1", listener2,"vasia2", "test");
+        MessageContext msgCtx2 = new MessageContext();
+        msgCtx2.setCorrelationID("vasia2");
+        msgCtx2.setType("response");
+        coreManager.getProtocolCallback().onResponse("second of vasia2",msgCtx2);
+
+        asyncRequest("threeResponseTest request 2", listener1,"vasia1", "test");
+        MessageContext msgCtx1 = new MessageContext();
+        msgCtx1.setCorrelationID("vasia1");
+        msgCtx1.setType("response");
+        coreManager.getProtocolCallback().onResponse("vasia1",msgCtx1);
+
+        asyncRequest("threeResponseTest request 3", listener3,"vasia3", "test");
+        MessageContext msgCtx3 = new MessageContext();
+        msgCtx3.setCorrelationID("vasia3");
+        msgCtx3.setType("response");
+        coreManager.getProtocolCallback().onResponse("three1",msgCtx3);
+
+        coreManager.getProtocolCallback().onResponse("three2", msgCtx3);
+
+        coreManager.getProtocolCallback().onResponse("first1", msgCtx1);
+        Thread.sleep(250);
+
+        coreManager.getProtocolCallback().onResponse("first2", msgCtx1);
+        Thread.sleep(10000);
+    }
+
+    private class ListenerImpl implements ICoreAsyncResponseHandler{
+
+        public boolean onResponse(String message, String type) {
+            System.out.println("callback " + message);
+            return message != null;
+        }
+
+        @Override
+        public void onException(Exception e) {
+            e.printStackTrace();
+        }
+    }
+
+    private class SleeepListenerImpl implements ICoreAsyncResponseHandler{
+
+        public boolean onResponse(String message, String type) {
+            try {
+                Thread.sleep(150);
+                System.out.println("sleep callback " + message);
+            } catch (InterruptedException e) {
+                e.printStackTrace();
+            }
+            return message != null;
+        }
+
+        @Override
+        public void onException(Exception e) {
+            e.printStackTrace();
+        }
+    }
+
+    class CoreManagerTest extends CoreManager{
+        CoreManagerTest(Properties properties) throws CoreException {
+            super(properties);
+            protocol = mock(AsyncProtocol.class);
+        }
+        protected void sendRequest2Protocol(String request, String corrId, String rpcName) throws CoreException {
+        }
+
+        protected void initProtocol(Properties properties, RetrieveMessageCallback protocolCallback) throws ProtocolException {
+
+        }
+    }
+}
diff --git a/appc-client/client-lib/src/test/java/org/openecomp/appc/client/impl/core/SyncFlowTest.java b/appc-client/client-lib/src/test/java/org/openecomp/appc/client/impl/core/SyncFlowTest.java
new file mode 100644
index 0000000..4b4bce5
--- /dev/null
+++ b/appc-client/client-lib/src/test/java/org/openecomp/appc/client/impl/core/SyncFlowTest.java
@@ -0,0 +1,151 @@
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP : APPC
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Copyright (C) 2017 Amdocs
+ * =============================================================================
+ * 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.
+ * 
+ * ECOMP is a trademark and service mark of AT&T Intellectual Property.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.openecomp.appc.client.impl.core;
+
+import org.openecomp.appc.client.impl.core.CoreException;
+import org.openecomp.appc.client.impl.core.CoreManager;
+import org.openecomp.appc.client.impl.core.ICoreSyncResponseHandler;
+import org.openecomp.appc.client.impl.core.MessageContext;
+import org.openecomp.appc.client.impl.core.SyncRequestResponseHandler;
+import org.openecomp.appc.client.impl.protocol.AsyncProtocol;
+import org.openecomp.appc.client.impl.protocol.ProtocolException;
+import org.openecomp.appc.client.impl.protocol.RetrieveMessageCallback;
+import org.junit.Assert;
+import org.junit.Before;
+
+import java.util.Properties;
+import java.util.concurrent.ExecutorService;
+import java.util.concurrent.Executors;
+import java.util.concurrent.TimeoutException;
+
+import static org.mockito.Mockito.mock;
+
+public class SyncFlowTest {
+    CoreManager coreManager = null;
+
+    public void initialize() throws CoreException {
+        Properties prop = new Properties();
+        prop.setProperty("client.pool.size", "10");
+        prop.setProperty("client.response.timeout", "7000");
+        coreManager = new CoreManagerTest(prop);
+    }
+
+    <T> T syncRequest(String request, ICoreSyncResponseHandler businessCallback, String correlationId, String rpcName ) throws CoreException, TimeoutException {
+        SyncRequestResponseHandler requestResponseHandler = new SyncRequestResponseHandler(correlationId, businessCallback, coreManager);
+        requestResponseHandler.sendRequest(request, correlationId, rpcName);
+        T responseObject = (T) requestResponseHandler.getResponse();
+        return responseObject;
+    }
+
+    public void blockRequestTest(){
+        ICoreSyncResponseHandler handler = new ICoreSyncResponseHandlerImpl1();
+        try {
+            syncRequest("request 1", handler, "vasia1", "test");
+        }catch (Throwable e){
+            e.printStackTrace();
+            Assert.assertTrue(e != null);
+        }
+
+    }
+
+    public <T> void blockRequestSucceedTest() throws InterruptedException {
+        ExecutorService executorService = Executors.newFixedThreadPool(2);
+        final ICoreSyncResponseHandler handler = new ICoreSyncResponseHandlerImpl1();
+        try {
+            executorService.submit(new Runnable() {
+                public void run() {
+                    System.out.println("Send request");
+                    T response;
+                    try {
+                        response = syncRequest("request 1", handler, "vasia1", "test");
+                        System.out.println("=======" + response.toString());
+                    } catch (CoreException e) {
+                        e.printStackTrace();
+                    } catch (TimeoutException e) {
+                        e.printStackTrace();
+                    }
+                }
+            });
+        }catch (Throwable e){
+            Assert.assertTrue((RuntimeException)e != null);
+        }
+        Thread.sleep(2000);
+        executorService.submit(new Runnable() {
+            public void run() {
+                MessageContext ctx = new MessageContext();
+                ctx.setCorrelationID("vasia1");
+                ctx.setType("response");
+                try {
+                    System.out.println("Send response 1");
+                    coreManager.getProtocolCallback().onResponse("response for request 1", ctx);
+                } catch (Exception e) {
+                    e.printStackTrace();
+                }
+            }
+        });
+
+        Thread.sleep(2000);
+        executorService.submit(new Runnable() {
+            public void run() {
+                MessageContext ctx = new MessageContext();
+                ctx.setCorrelationID("vasia1");
+                ctx.setType("response");
+                try {
+                    System.out.println("Send response 2");
+                    coreManager.getProtocolCallback().onResponse("response for request 1 final", ctx);
+                } catch (Exception e) {
+                    e.printStackTrace();
+                }
+            }
+        });
+        Thread.sleep(1000);
+
+    }
+
+    class ICoreSyncResponseHandlerImpl1 implements ICoreSyncResponseHandler{
+
+
+        public <T> T onResponse(String message, String type) {
+            System.out.println("Received message = " + message) ;
+            if(message.contains("final")){
+                return (T) new String(message);
+            }
+            return null;
+        }
+    }
+
+    class CoreManagerTest extends CoreManager{
+        CoreManagerTest(Properties properties) throws CoreException {
+            super(properties);
+            protocol = mock(AsyncProtocol.class);
+        }
+        protected void sendRequest2Protocol(String request, String corrId, String rpcName) throws CoreException {
+        }
+
+        protected void initProtocol(Properties properties, RetrieveMessageCallback protocolCallback) throws ProtocolException{
+
+        }
+    }
+}
diff --git a/appc-client/client-lib/src/test/java/org/openecomp/appc/client/impl/protocol/APPCMessageReaderWriterTest.java b/appc-client/client-lib/src/test/java/org/openecomp/appc/client/impl/protocol/APPCMessageReaderWriterTest.java
new file mode 100644
index 0000000..91f6157
--- /dev/null
+++ b/appc-client/client-lib/src/test/java/org/openecomp/appc/client/impl/protocol/APPCMessageReaderWriterTest.java
@@ -0,0 +1,104 @@
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP : APPC
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Copyright (C) 2017 Amdocs
+ * =============================================================================
+ * 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.
+ * 
+ * ECOMP is a trademark and service mark of AT&T Intellectual Property.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.openecomp.appc.client.impl.protocol;
+
+import org.openecomp.appc.client.impl.core.MessageContext;
+import org.openecomp.appc.client.impl.protocol.APPCMessageReaderWriter;
+import org.openecomp.appc.client.impl.protocol.ProtocolException;
+
+import com.fasterxml.jackson.core.JsonFactory;
+import com.fasterxml.jackson.core.JsonGenerator;
+import com.fasterxml.jackson.databind.JsonNode;
+import com.fasterxml.jackson.databind.ObjectMapper;
+import com.fasterxml.jackson.databind.node.JsonNodeFactory;
+import com.fasterxml.jackson.databind.node.ObjectNode;
+import org.junit.AfterClass;
+import org.junit.Assert;
+import org.junit.Before;
+import org.junit.Test;
+
+import java.io.IOException;
+import java.io.StringWriter;
+
+public class APPCMessageReaderWriterTest {
+
+    private APPCMessageReaderWriter messageReaderWriter;
+    private ObjectMapper mapper;
+
+    private static final String VERSION = "2.0";
+    private static final String TYPE = "typeTest";
+    private static final String CORRELATION_ID = "correlationIdTest";
+    private static final String PARTITION = "partitionTest";
+    private static final String RPC = "rpcTest";
+    private static final String PAYLOAD = "{\"key1\":\"val1\",\"key2\":\"val2\",\"key3\":{\"key3.1\":\"val3.1\"}}";
+
+    @Before
+    public void init() throws IOException {
+        mapper = new ObjectMapper();
+        messageReaderWriter = new APPCMessageReaderWriter();
+    }
+
+    @Test
+    public void writeTest() throws IOException, ProtocolException {
+        MessageContext context = new MessageContext();
+        context.setType(TYPE);
+        context.setCorrelationID(CORRELATION_ID);
+        context.setPartiton(PARTITION);
+        context.setRpc(RPC);
+        String payload = PAYLOAD;
+        String message = messageReaderWriter.write(payload, context);
+
+        JsonNode messageJson = mapper.readTree(message);
+        Assert.assertEquals(VERSION, messageJson.get("version").asText());
+        Assert.assertEquals(context.getType(), messageJson.get("type").asText());
+        Assert.assertEquals(context.getCorrelationID(), messageJson.get("correlation-id").asText());
+        Assert.assertEquals(context.getPartiton(), messageJson.get("cambria.partition").asText());
+        Assert.assertEquals(context.getRpc(), messageJson.get("rpc-name").asText());
+        Assert.assertEquals(payload, messageJson.get("body").toString());
+    }
+
+    @Test
+    public void readTest() throws IOException, ProtocolException {
+        ObjectNode node = mapper.createObjectNode();
+        node.put("version", VERSION);
+        node.put("type", TYPE);
+        node.put("correlation-id", CORRELATION_ID);
+        node.put("cambria.partition", PARTITION);
+        node.put("rpc-name", RPC);
+        JsonNode payload = mapper.valueToTree(PAYLOAD);
+        node.set("body", payload);
+        String message = node.toString();
+
+        MessageContext returnContext = new MessageContext();
+        String returnPayload = messageReaderWriter.read(message, returnContext);
+
+        Assert.assertEquals(TYPE, returnContext.getType());
+        Assert.assertEquals(CORRELATION_ID, returnContext.getCorrelationID());
+        Assert.assertEquals(PARTITION, returnContext.getPartiton());
+        Assert.assertEquals(RPC, returnContext.getRpc());
+        Assert.assertEquals(payload.toString(), returnPayload);
+    }
+
+}
diff --git a/appc-client/client-lib/src/test/java/org/openecomp/appc/client/impl/protocol/TestAsyncProtocolImpl.java b/appc-client/client-lib/src/test/java/org/openecomp/appc/client/impl/protocol/TestAsyncProtocolImpl.java
new file mode 100644
index 0000000..046f5a8
--- /dev/null
+++ b/appc-client/client-lib/src/test/java/org/openecomp/appc/client/impl/protocol/TestAsyncProtocolImpl.java
@@ -0,0 +1,91 @@
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP : APPC
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Copyright (C) 2017 Amdocs
+ * =============================================================================
+ * 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.
+ * 
+ * ECOMP is a trademark and service mark of AT&T Intellectual Property.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.openecomp.appc.client.impl.protocol;
+
+import org.openecomp.appc.client.impl.core.MessageContext;
+import org.openecomp.appc.client.impl.protocol.AsyncProtocol;
+import org.openecomp.appc.client.impl.protocol.AsyncProtocolImpl;
+import org.openecomp.appc.client.impl.protocol.ProtocolException;
+import org.openecomp.appc.client.impl.protocol.RetrieveMessageCallback;
+import org.openecomp.appc.client.impl.protocol.UEBPropertiesKeys;
+import org.junit.Assert;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+import java.io.IOException;
+import java.io.InputStream;
+import java.util.Properties;
+import java.util.concurrent.atomic.AtomicBoolean;
+
+public class TestAsyncProtocolImpl {
+
+    private static AsyncProtocol protocol;
+    private static AtomicBoolean gotResponse;
+    private static Properties props;
+
+    private static class TestCallback implements RetrieveMessageCallback{
+
+        public void onResponse(String payload, MessageContext context) {
+            Assert.assertNotEquals(null, payload);
+            Assert.assertNotEquals(null, context);
+            protocol = null;
+            gotResponse.set(true);
+        }
+    }
+
+    @BeforeClass
+    public static void setUp() throws IOException, ProtocolException {
+
+        gotResponse = new AtomicBoolean(false);
+
+        props = new Properties();
+        String propFileName = "ueb.properties";
+
+        InputStream input = TestAsyncProtocolImpl.class.getClassLoader().getResourceAsStream(propFileName);
+
+        props.load(input);
+
+        protocol = new AsyncProtocolImpl();
+        protocol.init(props, new TestCallback());
+    }
+
+    public void testSendRequest() throws ProtocolException {
+
+        MessageContext context = new MessageContext();
+        context.setType("Test");
+
+        protocol.sendRequest("{\"Test\":\"\"}", context);
+
+        try {
+            Long timeToSleep = Long.parseLong((String)props.get(UEBPropertiesKeys.TOPIC_READ_TIMEOUT))*2;
+            Thread.sleep(timeToSleep);
+        } catch (InterruptedException e) {
+            Assert.assertFalse(e.getMessage(), false);
+        }
+        if (gotResponse.get() == false) {
+            Assert.assertFalse("Message was not read !", true);
+        }
+    }
+}
diff --git a/appc-client/client-lib/src/test/java/org/openecomp/appc/client/impl/protocol/TestAsyncProtocolImplMissingProps.java b/appc-client/client-lib/src/test/java/org/openecomp/appc/client/impl/protocol/TestAsyncProtocolImplMissingProps.java
new file mode 100644
index 0000000..9611a79
--- /dev/null
+++ b/appc-client/client-lib/src/test/java/org/openecomp/appc/client/impl/protocol/TestAsyncProtocolImplMissingProps.java
@@ -0,0 +1,75 @@
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP : APPC
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Copyright (C) 2017 Amdocs
+ * =============================================================================
+ * 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.
+ * 
+ * ECOMP is a trademark and service mark of AT&T Intellectual Property.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.openecomp.appc.client.impl.protocol;
+
+import org.openecomp.appc.client.impl.core.MessageContext;
+import org.openecomp.appc.client.impl.protocol.AsyncProtocol;
+import org.openecomp.appc.client.impl.protocol.AsyncProtocolImpl;
+import org.openecomp.appc.client.impl.protocol.RetrieveMessageCallback;
+import org.junit.Assert;
+import org.junit.Test;
+
+import java.io.IOException;
+import java.io.InputStream;
+import java.util.Properties;
+
+public class TestAsyncProtocolImplMissingProps {
+
+    private static AsyncProtocol protocol;
+
+    private static class TestCallback implements RetrieveMessageCallback {
+
+        public void onResponse(String payload, MessageContext context) {
+            Assert.assertFalse("bad Callback !",false);
+        }
+    }
+
+    @Test
+    /**
+     * protocol should throw illegal argument exception due to null properties
+     */
+    public void testSetUpMissingProps() {
+
+        Properties props = new Properties();
+        String propFileName = "ueb.missing.properties";
+
+        InputStream input = TestAsyncProtocolImplMissingProps.class.getClassLoader().getResourceAsStream(propFileName);
+
+        try {
+            props.load(input);
+        } catch (IOException e) {
+            Assert.assertFalse(e.getMessage(),false);
+        }
+
+        protocol = new AsyncProtocolImpl();
+        try {
+            protocol.init(props, new TestCallback());
+        } catch (IllegalArgumentException e) {
+            Assert.assertTrue(true);
+        } catch (Exception e) {
+            Assert.assertFalse(e.getMessage(),false);
+        }
+    }
+}
diff --git a/appc-client/client-lib/src/test/java/org/openecomp/appc/client/impl/protocol/TestAsyncProtocolImplNullCallback.java b/appc-client/client-lib/src/test/java/org/openecomp/appc/client/impl/protocol/TestAsyncProtocolImplNullCallback.java
new file mode 100644
index 0000000..e537037
--- /dev/null
+++ b/appc-client/client-lib/src/test/java/org/openecomp/appc/client/impl/protocol/TestAsyncProtocolImplNullCallback.java
@@ -0,0 +1,60 @@
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP : APPC
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Copyright (C) 2017 Amdocs
+ * =============================================================================
+ * 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.
+ * 
+ * ECOMP is a trademark and service mark of AT&T Intellectual Property.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.openecomp.appc.client.impl.protocol;
+
+import org.junit.Assert;
+import org.junit.Test;
+import org.openecomp.appc.client.impl.protocol.AsyncProtocol;
+import org.openecomp.appc.client.impl.protocol.AsyncProtocolImpl;
+import org.openecomp.appc.client.impl.protocol.ProtocolException;
+
+import java.io.IOException;
+import java.io.InputStream;
+import java.util.Properties;
+
+public class TestAsyncProtocolImplNullCallback {
+
+    private static AsyncProtocol protocol;
+
+    public void testSetUpNoCallback() throws IOException {
+
+        Properties props = new Properties();
+        String propFileName = "ueb.properties";
+
+        InputStream input = TestAsyncProtocolImpl.class.getClassLoader().getResourceAsStream(propFileName);
+
+        props.load(input);
+
+        protocol = new AsyncProtocolImpl();
+
+        try {
+            protocol.init(props, null);
+        } catch (ProtocolException e) {
+            Assert.assertTrue(true);
+        } catch (Exception e){
+            Assert.assertFalse(e.getMessage(),false);
+        }
+    }
+}
diff --git a/appc-client/client-lib/src/test/java/org/openecomp/appc/client/impl/protocol/TestUEBMessagingService.java b/appc-client/client-lib/src/test/java/org/openecomp/appc/client/impl/protocol/TestUEBMessagingService.java
new file mode 100644
index 0000000..109065a
--- /dev/null
+++ b/appc-client/client-lib/src/test/java/org/openecomp/appc/client/impl/protocol/TestUEBMessagingService.java
@@ -0,0 +1,70 @@
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP : APPC
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Copyright (C) 2017 Amdocs
+ * =============================================================================
+ * 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.
+ * 
+ * ECOMP is a trademark and service mark of AT&T Intellectual Property.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.openecomp.appc.client.impl.protocol;
+
+import org.junit.*;
+import org.junit.runners.MethodSorters;
+import org.openecomp.appc.client.impl.protocol.MessagingService;
+import org.openecomp.appc.client.impl.protocol.UEBMessagingService;
+
+import java.io.IOException;
+import java.io.InputStream;
+import java.security.GeneralSecurityException;
+import java.util.List;
+import java.util.Properties;
+
+@FixMethodOrder(MethodSorters.NAME_ASCENDING)
+public class TestUEBMessagingService {
+
+    private static MessagingService ueb;
+
+    public static void setUp() throws IOException, GeneralSecurityException, NoSuchFieldException, IllegalAccessException {
+
+        Properties props = new Properties();
+        String propFileName = "ueb.properties";
+
+        InputStream input = TestUEBMessagingService.class.getClassLoader().getResourceAsStream(propFileName);
+
+        props.load(input);
+
+        ueb = new UEBMessagingService();
+        ueb.init(props);
+    }
+
+    public void test1Send() throws IOException {
+    System.out.println("Here");
+
+        String message = "Test Message Service";
+        ueb.send(null,message);
+    }
+
+    public void test2Fetch() throws IOException {
+
+    System.out.println("Here2");
+        List<String> messages = ueb.fetch(1);
+        Assert.assertEquals(1,messages.size());
+    }
+
+}
diff --git a/appc-client/client-lib/src/test/resources/ueb.missing.properties b/appc-client/client-lib/src/test/resources/ueb.missing.properties
new file mode 100644
index 0000000..54ba582
--- /dev/null
+++ b/appc-client/client-lib/src/test/resources/ueb.missing.properties
@@ -0,0 +1,30 @@
+###
+# ============LICENSE_START=======================================================
+# ONAP : APPC
+# ================================================================================
+# Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+# ================================================================================
+# Copyright (C) 2017 Amdocs
+# =============================================================================
+# 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.
+# 
+# ECOMP is a trademark and service mark of AT&T Intellectual Property.
+# ============LICENSE_END=========================================================
+###
+
+topic.read=APPC-UNIT-TEST
+topic.read.timeout=60000
+topic.write=APPC-UNIT-TEST
+client.name=APPC-CLIENT
+client.id=0
+
diff --git a/appc-client/client-lib/src/test/resources/ueb.properties b/appc-client/client-lib/src/test/resources/ueb.properties
new file mode 100644
index 0000000..026d5f4
--- /dev/null
+++ b/appc-client/client-lib/src/test/resources/ueb.properties
@@ -0,0 +1,29 @@
+###
+# ============LICENSE_START=======================================================
+# ONAP : APPC
+# ================================================================================
+# Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+# ================================================================================
+# Copyright (C) 2017 Amdocs
+# =============================================================================
+# 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.
+# 
+# ECOMP is a trademark and service mark of AT&T Intellectual Property.
+# ============LICENSE_END=========================================================
+###
+
+poolMembers=10.147.29.67:3904
+topic.read=APPC-TEST1
+topic.read.timeout=2500
+topic.write=APPC-TEST1
+
