diff --git a/pom.xml b/pom.xml
index 1da2616..42400c5 100644
--- a/pom.xml
+++ b/pom.xml
@@ -15,7 +15,7 @@
 	<groupId>org.onap.dmaap.messagerouter.dmaapclient</groupId>
 	<artifactId>dmaapClient</artifactId>
 	<packaging>jar</packaging>
-	<version>1.1.8-SNAPSHOT</version>
+	<version>1.1.9-SNAPSHOT</version>
 	<name>dmaap-messagerouter-dmaapclient</name>
 	<description>Client library for MR event routing API</description>
 	<url>https://github.com/att/dmaap-framework</url>
diff --git a/src/main/java/com/att/nsa/mr/client/HostSelector.java b/src/main/java/org/onap/dmaap/mr/client/HostSelector.java
similarity index 99%
rename from src/main/java/com/att/nsa/mr/client/HostSelector.java
rename to src/main/java/org/onap/dmaap/mr/client/HostSelector.java
index 63ef404..9bd73f9 100644
--- a/src/main/java/com/att/nsa/mr/client/HostSelector.java
+++ b/src/main/java/org/onap/dmaap/mr/client/HostSelector.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.client;
+package org.onap.dmaap.mr.client;
 
 import java.util.Collection;
 import java.util.Iterator;
diff --git a/src/main/java/com/att/nsa/mr/client/MRBatchingPublisher.java b/src/main/java/org/onap/dmaap/mr/client/MRBatchingPublisher.java
similarity index 95%
rename from src/main/java/com/att/nsa/mr/client/MRBatchingPublisher.java
rename to src/main/java/org/onap/dmaap/mr/client/MRBatchingPublisher.java
index 875b5a3..df440bb 100644
--- a/src/main/java/com/att/nsa/mr/client/MRBatchingPublisher.java
+++ b/src/main/java/org/onap/dmaap/mr/client/MRBatchingPublisher.java
@@ -19,12 +19,12 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.client;
+package org.onap.dmaap.mr.client;
 
 import java.io.IOException;
 import java.util.List;
 import java.util.concurrent.TimeUnit;
-import com.att.nsa.mr.client.response.MRPublisherResponse;
+import org.onap.dmaap.mr.client.response.MRPublisherResponse;
 
 /**
  * A MR batching publisher is a publisher with additional functionality
diff --git a/src/main/java/com/att/nsa/mr/client/MRClient.java b/src/main/java/org/onap/dmaap/mr/client/MRClient.java
similarity index 98%
rename from src/main/java/com/att/nsa/mr/client/MRClient.java
rename to src/main/java/org/onap/dmaap/mr/client/MRClient.java
index f3a8f43..8cbf9e0 100644
--- a/src/main/java/com/att/nsa/mr/client/MRClient.java
+++ b/src/main/java/org/onap/dmaap/mr/client/MRClient.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.client;
+package org.onap.dmaap.mr.client;
 
 import org.slf4j.Logger;
 
diff --git a/src/main/java/com/att/nsa/mr/client/MRClientBuilders.java b/src/main/java/org/onap/dmaap/mr/client/MRClientBuilders.java
similarity index 98%
rename from src/main/java/com/att/nsa/mr/client/MRClientBuilders.java
rename to src/main/java/org/onap/dmaap/mr/client/MRClientBuilders.java
index 73ef5c4..60e0666 100644
--- a/src/main/java/com/att/nsa/mr/client/MRClientBuilders.java
+++ b/src/main/java/org/onap/dmaap/mr/client/MRClientBuilders.java
@@ -21,7 +21,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.client;
+package org.onap.dmaap.mr.client;
 
 import java.net.MalformedURLException;
 import java.util.Collection;
@@ -31,9 +31,9 @@
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import com.att.nsa.mr.client.impl.MRConsumerImpl;
-import com.att.nsa.mr.client.impl.MRMetaClient;
-import com.att.nsa.mr.client.impl.MRSimplerBatchPublisher;
+import org.onap.dmaap.mr.client.impl.MRConsumerImpl;
+import org.onap.dmaap.mr.client.impl.MRMetaClient;
+import org.onap.dmaap.mr.client.impl.MRSimplerBatchPublisher;
 
 /**
  * A collection of builders for various types of MR API clients
diff --git a/src/main/java/com/att/nsa/mr/client/MRClientFactory.java b/src/main/java/org/onap/dmaap/mr/client/MRClientFactory.java
similarity index 98%
rename from src/main/java/com/att/nsa/mr/client/MRClientFactory.java
rename to src/main/java/org/onap/dmaap/mr/client/MRClientFactory.java
index 689190e..dc9d555 100644
--- a/src/main/java/com/att/nsa/mr/client/MRClientFactory.java
+++ b/src/main/java/org/onap/dmaap/mr/client/MRClientFactory.java
@@ -21,7 +21,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.client;
+package org.onap.dmaap.mr.client;
 
 import java.io.File;
 import java.io.FileNotFoundException;
@@ -37,11 +37,11 @@
 
 import javax.ws.rs.core.MultivaluedMap;
 
-import com.att.nsa.mr.client.impl.MRConsumerImpl;
-import com.att.nsa.mr.client.impl.MRMetaClient;
-import com.att.nsa.mr.client.impl.MRSimplerBatchPublisher;
-import com.att.nsa.mr.test.clients.ProtocolTypeConstants;
-import com.att.nsa.mr.tools.ValidatorUtil;
+import org.onap.dmaap.mr.client.impl.MRConsumerImpl;
+import org.onap.dmaap.mr.client.impl.MRMetaClient;
+import org.onap.dmaap.mr.client.impl.MRSimplerBatchPublisher;
+import org.onap.dmaap.mr.test.clients.ProtocolTypeConstants;
+import org.onap.dmaap.mr.tools.ValidatorUtil;
 
 /**
  * A factory for MR clients.<br/>
diff --git a/src/main/java/com/att/nsa/mr/client/MRConsumer.java b/src/main/java/org/onap/dmaap/mr/client/MRConsumer.java
similarity index 95%
rename from src/main/java/com/att/nsa/mr/client/MRConsumer.java
rename to src/main/java/org/onap/dmaap/mr/client/MRConsumer.java
index 444eb7c..b2f7563 100644
--- a/src/main/java/com/att/nsa/mr/client/MRConsumer.java
+++ b/src/main/java/org/onap/dmaap/mr/client/MRConsumer.java
@@ -19,11 +19,11 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.client;
+package org.onap.dmaap.mr.client;
 
 import java.io.IOException;
 
-import com.att.nsa.mr.client.response.MRConsumerResponse;
+import org.onap.dmaap.mr.client.response.MRConsumerResponse;
 
 public interface MRConsumer extends MRClient
 {
diff --git a/src/main/java/com/att/nsa/mr/client/MRIdentityManager.java b/src/main/java/org/onap/dmaap/mr/client/MRIdentityManager.java
similarity index 98%
rename from src/main/java/com/att/nsa/mr/client/MRIdentityManager.java
rename to src/main/java/org/onap/dmaap/mr/client/MRIdentityManager.java
index 5483761..1905f82 100644
--- a/src/main/java/com/att/nsa/mr/client/MRIdentityManager.java
+++ b/src/main/java/org/onap/dmaap/mr/client/MRIdentityManager.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.client;
+package org.onap.dmaap.mr.client;
 
 import java.io.IOException;
 
diff --git a/src/main/java/com/att/nsa/mr/client/MRPublisher.java b/src/main/java/org/onap/dmaap/mr/client/MRPublisher.java
similarity index 98%
rename from src/main/java/com/att/nsa/mr/client/MRPublisher.java
rename to src/main/java/org/onap/dmaap/mr/client/MRPublisher.java
index 651c548..e900229 100644
--- a/src/main/java/com/att/nsa/mr/client/MRPublisher.java
+++ b/src/main/java/org/onap/dmaap/mr/client/MRPublisher.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.client;
+package org.onap.dmaap.mr.client;
 
 import java.io.IOException;
 import java.util.Collection;
diff --git a/src/main/java/com/att/nsa/mr/client/MRTopicManager.java b/src/main/java/org/onap/dmaap/mr/client/MRTopicManager.java
similarity index 99%
rename from src/main/java/com/att/nsa/mr/client/MRTopicManager.java
rename to src/main/java/org/onap/dmaap/mr/client/MRTopicManager.java
index 13524bd..54ca7ec 100644
--- a/src/main/java/com/att/nsa/mr/client/MRTopicManager.java
+++ b/src/main/java/org/onap/dmaap/mr/client/MRTopicManager.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.client;
+package org.onap.dmaap.mr.client;
 
 import java.io.IOException;
 import java.util.Set;
diff --git a/src/main/java/com/att/nsa/mr/client/impl/Clock.java b/src/main/java/org/onap/dmaap/mr/client/impl/Clock.java
similarity index 97%
rename from src/main/java/com/att/nsa/mr/client/impl/Clock.java
rename to src/main/java/org/onap/dmaap/mr/client/impl/Clock.java
index ace791e..6670399 100644
--- a/src/main/java/com/att/nsa/mr/client/impl/Clock.java
+++ b/src/main/java/org/onap/dmaap/mr/client/impl/Clock.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.client.impl;
+package org.onap.dmaap.mr.client.impl;
 
 public class Clock
 {
diff --git a/src/main/java/com/att/nsa/mr/client/impl/DmaapClientUtil.java b/src/main/java/org/onap/dmaap/mr/client/impl/DmaapClientUtil.java
similarity index 98%
rename from src/main/java/com/att/nsa/mr/client/impl/DmaapClientUtil.java
rename to src/main/java/org/onap/dmaap/mr/client/impl/DmaapClientUtil.java
index a3a2ce1..b06290a 100644
--- a/src/main/java/com/att/nsa/mr/client/impl/DmaapClientUtil.java
+++ b/src/main/java/org/onap/dmaap/mr/client/impl/DmaapClientUtil.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.client.impl;
+package org.onap.dmaap.mr.client.impl;
 
 import javax.ws.rs.client.Client;
 import javax.ws.rs.client.ClientBuilder;
diff --git a/src/main/java/com/att/nsa/mr/client/impl/MRBaseClient.java b/src/main/java/org/onap/dmaap/mr/client/impl/MRBaseClient.java
similarity index 98%
rename from src/main/java/com/att/nsa/mr/client/impl/MRBaseClient.java
rename to src/main/java/org/onap/dmaap/mr/client/impl/MRBaseClient.java
index 76bf5ce..ecea21c 100644
--- a/src/main/java/com/att/nsa/mr/client/impl/MRBaseClient.java
+++ b/src/main/java/org/onap/dmaap/mr/client/impl/MRBaseClient.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.client.impl;
+package org.onap.dmaap.mr.client.impl;
 
 import java.net.MalformedURLException;
 import java.util.Collection;
@@ -41,9 +41,9 @@
 
 import com.att.nsa.apiClient.http.CacheUse;
 import com.att.nsa.apiClient.http.HttpClient;
-import com.att.nsa.mr.client.MRClient;
-import com.att.nsa.mr.client.MRClientFactory;
-import com.att.nsa.mr.test.clients.ProtocolTypeConstants;
+import org.onap.dmaap.mr.client.MRClient;
+import org.onap.dmaap.mr.client.MRClientFactory;
+import org.onap.dmaap.mr.test.clients.ProtocolTypeConstants;
 
 public class MRBaseClient extends HttpClient implements MRClient {
 
diff --git a/src/main/java/com/att/nsa/mr/client/impl/MRBatchPublisher.java b/src/main/java/org/onap/dmaap/mr/client/impl/MRBatchPublisher.java
similarity index 98%
rename from src/main/java/com/att/nsa/mr/client/impl/MRBatchPublisher.java
rename to src/main/java/org/onap/dmaap/mr/client/impl/MRBatchPublisher.java
index 7d1e396..bcd4403 100644
--- a/src/main/java/com/att/nsa/mr/client/impl/MRBatchPublisher.java
+++ b/src/main/java/org/onap/dmaap/mr/client/impl/MRBatchPublisher.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.client.impl;
+package org.onap.dmaap.mr.client.impl;
 
 import java.io.ByteArrayOutputStream;
 import java.io.IOException;
@@ -40,8 +40,8 @@
 
 import com.att.nsa.apiClient.http.HttpClient;
 import com.att.nsa.apiClient.http.HttpException;
-import com.att.nsa.mr.client.MRBatchingPublisher;
-import com.att.nsa.mr.client.response.MRPublisherResponse;
+import org.onap.dmaap.mr.client.MRBatchingPublisher;
+import org.onap.dmaap.mr.client.response.MRPublisherResponse;
 
 /**
  * This is a batching publisher class that allows the client to publish messages
diff --git a/src/main/java/com/att/nsa/mr/client/impl/MRClientVersionInfo.java b/src/main/java/org/onap/dmaap/mr/client/impl/MRClientVersionInfo.java
similarity index 97%
rename from src/main/java/com/att/nsa/mr/client/impl/MRClientVersionInfo.java
rename to src/main/java/org/onap/dmaap/mr/client/impl/MRClientVersionInfo.java
index bb6299d..ed23918 100644
--- a/src/main/java/com/att/nsa/mr/client/impl/MRClientVersionInfo.java
+++ b/src/main/java/org/onap/dmaap/mr/client/impl/MRClientVersionInfo.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.client.impl;
+package org.onap.dmaap.mr.client.impl;
 
 import java.io.IOException;
 import java.io.InputStream;
diff --git a/src/main/java/com/att/nsa/mr/client/impl/MRConstants.java b/src/main/java/org/onap/dmaap/mr/client/impl/MRConstants.java
similarity index 98%
rename from src/main/java/com/att/nsa/mr/client/impl/MRConstants.java
rename to src/main/java/org/onap/dmaap/mr/client/impl/MRConstants.java
index cb0fc31..f6d9578 100644
--- a/src/main/java/com/att/nsa/mr/client/impl/MRConstants.java
+++ b/src/main/java/org/onap/dmaap/mr/client/impl/MRConstants.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.client.impl;
+package org.onap.dmaap.mr.client.impl;
 
 import java.io.UnsupportedEncodingException;
 import java.net.URLEncoder;
diff --git a/src/main/java/com/att/nsa/mr/client/impl/MRConsumerImpl.java b/src/main/java/org/onap/dmaap/mr/client/impl/MRConsumerImpl.java
similarity index 98%
rename from src/main/java/com/att/nsa/mr/client/impl/MRConsumerImpl.java
rename to src/main/java/org/onap/dmaap/mr/client/impl/MRConsumerImpl.java
index bc156ea..a1a52aa 100644
--- a/src/main/java/com/att/nsa/mr/client/impl/MRConsumerImpl.java
+++ b/src/main/java/org/onap/dmaap/mr/client/impl/MRConsumerImpl.java
@@ -19,15 +19,15 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  * 
  *******************************************************************************/
-package com.att.nsa.mr.client.impl;
+package org.onap.dmaap.mr.client.impl;
 
 import com.att.aft.dme2.api.DME2Client;
 import com.att.aft.dme2.api.DME2Exception;
-import com.att.nsa.mr.client.HostSelector;
-import com.att.nsa.mr.client.MRClientFactory;
-import com.att.nsa.mr.client.MRConsumer;
-import com.att.nsa.mr.client.response.MRConsumerResponse;
-import com.att.nsa.mr.test.clients.ProtocolTypeConstants;
+import org.onap.dmaap.mr.client.HostSelector;
+import org.onap.dmaap.mr.client.MRClientFactory;
+import org.onap.dmaap.mr.client.MRConsumer;
+import org.onap.dmaap.mr.client.response.MRConsumerResponse;
+import org.onap.dmaap.mr.test.clients.ProtocolTypeConstants;
 import java.io.File;
 import java.io.FileReader;
 import java.io.IOException;
diff --git a/src/main/java/com/att/nsa/mr/client/impl/MRFormat.java b/src/main/java/org/onap/dmaap/mr/client/impl/MRFormat.java
similarity index 97%
rename from src/main/java/com/att/nsa/mr/client/impl/MRFormat.java
rename to src/main/java/org/onap/dmaap/mr/client/impl/MRFormat.java
index 1028adf..538f1e3 100644
--- a/src/main/java/com/att/nsa/mr/client/impl/MRFormat.java
+++ b/src/main/java/org/onap/dmaap/mr/client/impl/MRFormat.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.client.impl;
+package org.onap.dmaap.mr.client.impl;
 
 enum MRFormat
 {
diff --git a/src/main/java/com/att/nsa/mr/client/impl/MRMetaClient.java b/src/main/java/org/onap/dmaap/mr/client/impl/MRMetaClient.java
similarity index 97%
rename from src/main/java/com/att/nsa/mr/client/impl/MRMetaClient.java
rename to src/main/java/org/onap/dmaap/mr/client/impl/MRMetaClient.java
index 609540b..9051b99 100644
--- a/src/main/java/com/att/nsa/mr/client/impl/MRMetaClient.java
+++ b/src/main/java/org/onap/dmaap/mr/client/impl/MRMetaClient.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.client.impl;
+package org.onap.dmaap.mr.client.impl;
 
 import java.io.IOException;
 import java.net.MalformedURLException;
@@ -37,8 +37,8 @@
 import com.att.nsa.apiClient.credentials.ApiCredential;
 import com.att.nsa.apiClient.http.HttpException;
 import com.att.nsa.apiClient.http.HttpObjectNotFoundException;
-import com.att.nsa.mr.client.MRIdentityManager;
-import com.att.nsa.mr.client.MRTopicManager;
+import org.onap.dmaap.mr.client.MRIdentityManager;
+import org.onap.dmaap.mr.client.MRTopicManager;
 
 public class MRMetaClient extends MRBaseClient implements MRTopicManager, MRIdentityManager
 {
diff --git a/src/main/java/com/att/nsa/mr/client/impl/MRSimplerBatchPublisher.java b/src/main/java/org/onap/dmaap/mr/client/impl/MRSimplerBatchPublisher.java
similarity index 98%
rename from src/main/java/com/att/nsa/mr/client/impl/MRSimplerBatchPublisher.java
rename to src/main/java/org/onap/dmaap/mr/client/impl/MRSimplerBatchPublisher.java
index 4f44d30..c5eb3ba 100644
--- a/src/main/java/com/att/nsa/mr/client/impl/MRSimplerBatchPublisher.java
+++ b/src/main/java/org/onap/dmaap/mr/client/impl/MRSimplerBatchPublisher.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.client.impl;
+package org.onap.dmaap.mr.client.impl;
 
 import java.io.ByteArrayOutputStream;
 import java.io.IOException;
@@ -51,10 +51,10 @@
 
 import com.att.aft.dme2.api.DME2Client;
 import com.att.aft.dme2.api.DME2Exception;
-import com.att.nsa.mr.client.HostSelector;
-import com.att.nsa.mr.client.MRBatchingPublisher;
-import com.att.nsa.mr.client.response.MRPublisherResponse;
-import com.att.nsa.mr.test.clients.ProtocolTypeConstants;
+import org.onap.dmaap.mr.client.HostSelector;
+import org.onap.dmaap.mr.client.MRBatchingPublisher;
+import org.onap.dmaap.mr.client.response.MRPublisherResponse;
+import org.onap.dmaap.mr.test.clients.ProtocolTypeConstants;
 
 public class MRSimplerBatchPublisher extends MRBaseClient implements MRBatchingPublisher {
 	private static final Logger logger = LoggerFactory.getLogger(MRSimplerBatchPublisher.class);
diff --git a/src/main/java/com/att/nsa/mr/client/response/MRConsumerResponse.java b/src/main/java/org/onap/dmaap/mr/client/response/MRConsumerResponse.java
similarity index 97%
rename from src/main/java/com/att/nsa/mr/client/response/MRConsumerResponse.java
rename to src/main/java/org/onap/dmaap/mr/client/response/MRConsumerResponse.java
index 102794e..5dc3da0 100644
--- a/src/main/java/com/att/nsa/mr/client/response/MRConsumerResponse.java
+++ b/src/main/java/org/onap/dmaap/mr/client/response/MRConsumerResponse.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.client.response;
+package org.onap.dmaap.mr.client.response;
 
 public class MRConsumerResponse {
 	
diff --git a/src/main/java/com/att/nsa/mr/client/response/MRPublisherResponse.java b/src/main/java/org/onap/dmaap/mr/client/response/MRPublisherResponse.java
similarity index 97%
rename from src/main/java/com/att/nsa/mr/client/response/MRPublisherResponse.java
rename to src/main/java/org/onap/dmaap/mr/client/response/MRPublisherResponse.java
index 96c39d6..f0630be 100644
--- a/src/main/java/com/att/nsa/mr/client/response/MRPublisherResponse.java
+++ b/src/main/java/org/onap/dmaap/mr/client/response/MRPublisherResponse.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.client.response;
+package org.onap.dmaap.mr.client.response;
 
 /**
  * Response for Publisher
diff --git a/src/main/java/com/att/nsa/mr/dme/client/DefaultLoggingFailoverFaultHandler.java b/src/main/java/org/onap/dmaap/mr/dme/client/DefaultLoggingFailoverFaultHandler.java
similarity index 97%
rename from src/main/java/com/att/nsa/mr/dme/client/DefaultLoggingFailoverFaultHandler.java
rename to src/main/java/org/onap/dmaap/mr/dme/client/DefaultLoggingFailoverFaultHandler.java
index 4f04dec..a44d858 100644
--- a/src/main/java/com/att/nsa/mr/dme/client/DefaultLoggingFailoverFaultHandler.java
+++ b/src/main/java/org/onap/dmaap/mr/dme/client/DefaultLoggingFailoverFaultHandler.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.dme.client;
+package org.onap.dmaap.mr.dme.client;
 
 
 
diff --git a/src/main/java/com/att/nsa/mr/dme/client/HeaderReplyHandler.java b/src/main/java/org/onap/dmaap/mr/dme/client/HeaderReplyHandler.java
similarity index 93%
rename from src/main/java/com/att/nsa/mr/dme/client/HeaderReplyHandler.java
rename to src/main/java/org/onap/dmaap/mr/dme/client/HeaderReplyHandler.java
index 4363902..da0ba62 100644
--- a/src/main/java/com/att/nsa/mr/dme/client/HeaderReplyHandler.java
+++ b/src/main/java/org/onap/dmaap/mr/dme/client/HeaderReplyHandler.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.dme.client;
+package org.onap.dmaap.mr.dme.client;
 
 
 import java.util.Map;
@@ -30,8 +30,8 @@
 import com.att.aft.dme2.api.util.DME2ExchangeFaultContext;
 import com.att.aft.dme2.api.util.DME2ExchangeReplyHandler;
 import com.att.aft.dme2.api.util.DME2ExchangeResponseContext;
-import com.att.nsa.mr.client.MRClientFactory;
-import com.att.nsa.mr.client.impl.MRSimplerBatchPublisher;
+import org.onap.dmaap.mr.client.MRClientFactory;
+import org.onap.dmaap.mr.client.impl.MRSimplerBatchPublisher;
 
 
 
diff --git a/src/main/java/com/att/nsa/mr/dme/client/PreferredRouteReplyHandler.java b/src/main/java/org/onap/dmaap/mr/dme/client/PreferredRouteReplyHandler.java
similarity index 94%
rename from src/main/java/com/att/nsa/mr/dme/client/PreferredRouteReplyHandler.java
rename to src/main/java/org/onap/dmaap/mr/dme/client/PreferredRouteReplyHandler.java
index 2da5ce9..967ccf3 100644
--- a/src/main/java/com/att/nsa/mr/dme/client/PreferredRouteReplyHandler.java
+++ b/src/main/java/org/onap/dmaap/mr/dme/client/PreferredRouteReplyHandler.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.dme.client;
+package org.onap.dmaap.mr.dme.client;
 import java.io.File;
 import java.io.FileWriter;
 import java.io.InputStream;
@@ -30,8 +30,8 @@
 import com.att.aft.dme2.api.util.DME2ExchangeFaultContext;
 import com.att.aft.dme2.api.util.DME2ExchangeReplyHandler;
 import com.att.aft.dme2.api.util.DME2ExchangeResponseContext;
-import com.att.nsa.mr.client.MRClientFactory;
-import com.att.nsa.mr.client.impl.MRSimplerBatchPublisher;
+import org.onap.dmaap.mr.client.MRClientFactory;
+import org.onap.dmaap.mr.client.impl.MRSimplerBatchPublisher;
 
 public class PreferredRouteReplyHandler implements DME2ExchangeReplyHandler {
 	private Logger fLog = LoggerFactory.getLogger ( this.getClass().getName () );
diff --git a/src/main/java/com/att/nsa/mr/dme/client/PreferredRouteRequestHandler.java b/src/main/java/org/onap/dmaap/mr/dme/client/PreferredRouteRequestHandler.java
similarity index 95%
rename from src/main/java/com/att/nsa/mr/dme/client/PreferredRouteRequestHandler.java
rename to src/main/java/org/onap/dmaap/mr/dme/client/PreferredRouteRequestHandler.java
index fbc32a7..4c2e546 100644
--- a/src/main/java/com/att/nsa/mr/dme/client/PreferredRouteRequestHandler.java
+++ b/src/main/java/org/onap/dmaap/mr/dme/client/PreferredRouteRequestHandler.java
@@ -19,14 +19,14 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.dme.client;
+package org.onap.dmaap.mr.dme.client;
 
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
 import com.att.aft.dme2.api.util.DME2ExchangeRequestContext;
 import com.att.aft.dme2.api.util.DME2ExchangeRequestHandler;
-import com.att.nsa.mr.client.MRClientFactory;
+import org.onap.dmaap.mr.client.MRClientFactory;
 
 public class PreferredRouteRequestHandler implements DME2ExchangeRequestHandler {
 	private Logger logger = LoggerFactory.getLogger(this.getClass().getName());
diff --git a/src/main/java/com/att/nsa/mr/dme/client/SimpleExampleConsumer.java b/src/main/java/org/onap/dmaap/mr/dme/client/SimpleExampleConsumer.java
similarity index 95%
rename from src/main/java/com/att/nsa/mr/dme/client/SimpleExampleConsumer.java
rename to src/main/java/org/onap/dmaap/mr/dme/client/SimpleExampleConsumer.java
index ce0138c..6fb02a5 100644
--- a/src/main/java/com/att/nsa/mr/dme/client/SimpleExampleConsumer.java
+++ b/src/main/java/org/onap/dmaap/mr/dme/client/SimpleExampleConsumer.java
@@ -20,7 +20,7 @@
  *  
  *******************************************************************************/
 
-package com.att.nsa.mr.dme.client;
+package org.onap.dmaap.mr.dme.client;
 
 import java.util.Map;
 
@@ -29,8 +29,8 @@
 
 import javax.ws.rs.core.MultivaluedMap;
 
-import com.att.nsa.mr.client.MRClientFactory;
-import com.att.nsa.mr.client.MRConsumer;
+import org.onap.dmaap.mr.client.MRClientFactory;
+import org.onap.dmaap.mr.client.MRConsumer;
 
 import java.util.List;
 
diff --git a/src/main/java/com/att/nsa/mr/dme/client/SimpleExamplePublisher.java b/src/main/java/org/onap/dmaap/mr/dme/client/SimpleExamplePublisher.java
similarity index 95%
rename from src/main/java/com/att/nsa/mr/dme/client/SimpleExamplePublisher.java
rename to src/main/java/org/onap/dmaap/mr/dme/client/SimpleExamplePublisher.java
index f9e830c..edb3994 100644
--- a/src/main/java/com/att/nsa/mr/dme/client/SimpleExamplePublisher.java
+++ b/src/main/java/org/onap/dmaap/mr/dme/client/SimpleExamplePublisher.java
@@ -20,7 +20,7 @@
  *  
  *******************************************************************************/
 
-package com.att.nsa.mr.dme.client;
+package org.onap.dmaap.mr.dme.client;
 
 
 import java.io.IOException;
@@ -33,9 +33,9 @@
 
 import org.json.JSONObject;
 
-import com.att.nsa.mr.client.MRBatchingPublisher;
-import com.att.nsa.mr.client.MRClientFactory;
-import com.att.nsa.mr.client.MRPublisher.message;
+import org.onap.dmaap.mr.client.MRBatchingPublisher;
+import org.onap.dmaap.mr.client.MRClientFactory;
+import org.onap.dmaap.mr.client.MRPublisher.message;
 
 /**
  * An example of how to use the Java publisher.
diff --git a/src/main/java/com/att/nsa/mr/logging/MRAppender.java b/src/main/java/org/onap/dmaap/mr/logging/MRAppender.java
similarity index 96%
rename from src/main/java/com/att/nsa/mr/logging/MRAppender.java
rename to src/main/java/org/onap/dmaap/mr/logging/MRAppender.java
index 4bb3e71..8842b14 100644
--- a/src/main/java/com/att/nsa/mr/logging/MRAppender.java
+++ b/src/main/java/org/onap/dmaap/mr/logging/MRAppender.java
@@ -22,7 +22,7 @@
 /**
  * 
  */
-package com.att.nsa.mr.logging;
+package org.onap.dmaap.mr.logging;
 
 import java.io.IOException;
 
@@ -32,8 +32,8 @@
 import org.apache.log4j.AppenderSkeleton;
 import org.apache.log4j.spi.LoggingEvent;
 
-import com.att.nsa.mr.client.MRClientFactory;
-import com.att.nsa.mr.client.MRPublisher;
+import org.onap.dmaap.mr.client.MRClientFactory;
+import org.onap.dmaap.mr.client.MRPublisher;
 
 /**
  * @author author
diff --git a/src/main/java/com/att/nsa/mr/test/clients/ConsolePublisher.java b/src/main/java/org/onap/dmaap/mr/test/clients/ConsolePublisher.java
similarity index 93%
rename from src/main/java/com/att/nsa/mr/test/clients/ConsolePublisher.java
rename to src/main/java/org/onap/dmaap/mr/test/clients/ConsolePublisher.java
index 60971c1..62e4cda 100644
--- a/src/main/java/com/att/nsa/mr/test/clients/ConsolePublisher.java
+++ b/src/main/java/org/onap/dmaap/mr/test/clients/ConsolePublisher.java
@@ -20,7 +20,7 @@
  *  
  *******************************************************************************/
 
-package com.att.nsa.mr.test.clients;
+package org.onap.dmaap.mr.test.clients;
 
 import java.io.BufferedReader;
 import java.io.IOException;
@@ -32,9 +32,9 @@
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import com.att.nsa.mr.client.MRBatchingPublisher;
-import com.att.nsa.mr.client.MRClientFactory;
-import com.att.nsa.mr.client.MRPublisher.message;
+import org.onap.dmaap.mr.client.MRBatchingPublisher;
+import org.onap.dmaap.mr.client.MRClientFactory;
+import org.onap.dmaap.mr.client.MRPublisher.message;
 
 /**
  * A simple publisher that reads from std in, sending each line as a message. 
diff --git a/src/main/java/com/att/nsa/mr/test/clients/ProtocolTypeConstants.java b/src/main/java/org/onap/dmaap/mr/test/clients/ProtocolTypeConstants.java
similarity index 97%
rename from src/main/java/com/att/nsa/mr/test/clients/ProtocolTypeConstants.java
rename to src/main/java/org/onap/dmaap/mr/test/clients/ProtocolTypeConstants.java
index a4a176e..6ece7f7 100644
--- a/src/main/java/com/att/nsa/mr/test/clients/ProtocolTypeConstants.java
+++ b/src/main/java/org/onap/dmaap/mr/test/clients/ProtocolTypeConstants.java
@@ -22,7 +22,7 @@
 /**
  * 
  */
-package com.att.nsa.mr.test.clients;
+package org.onap.dmaap.mr.test.clients;
 
 /**
  * @author author
diff --git a/src/main/java/com/att/nsa/mr/test/clients/SampleConsumer.java b/src/main/java/org/onap/dmaap/mr/test/clients/SampleConsumer.java
similarity index 95%
rename from src/main/java/com/att/nsa/mr/test/clients/SampleConsumer.java
rename to src/main/java/org/onap/dmaap/mr/test/clients/SampleConsumer.java
index 44e5205..1f78be1 100644
--- a/src/main/java/com/att/nsa/mr/test/clients/SampleConsumer.java
+++ b/src/main/java/org/onap/dmaap/mr/test/clients/SampleConsumer.java
@@ -19,15 +19,15 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.test.clients;
+package org.onap.dmaap.mr.test.clients;
 
 import java.util.LinkedList;
 
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import com.att.nsa.mr.client.MRClientFactory;
-import com.att.nsa.mr.client.MRConsumer;
+import org.onap.dmaap.mr.client.MRClientFactory;
+import org.onap.dmaap.mr.client.MRConsumer;
 
 public class SampleConsumer {
     private SampleConsumer() {
diff --git a/src/main/java/com/att/nsa/mr/test/clients/SamplePublisher.java b/src/main/java/org/onap/dmaap/mr/test/clients/SamplePublisher.java
similarity index 91%
rename from src/main/java/com/att/nsa/mr/test/clients/SamplePublisher.java
rename to src/main/java/org/onap/dmaap/mr/test/clients/SamplePublisher.java
index 0233dcb..29d7f85 100644
--- a/src/main/java/com/att/nsa/mr/test/clients/SamplePublisher.java
+++ b/src/main/java/org/onap/dmaap/mr/test/clients/SamplePublisher.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.test.clients;
+package org.onap.dmaap.mr.test.clients;
 
 import java.io.IOException;
 import java.util.List;
@@ -29,10 +29,10 @@
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import com.att.nsa.mr.client.MRBatchingPublisher;
-import com.att.nsa.mr.client.MRClientFactory;
-import com.att.nsa.mr.client.MRClientBuilders.PublisherBuilder;
-import com.att.nsa.mr.client.MRPublisher.message;
+import org.onap.dmaap.mr.client.MRBatchingPublisher;
+import org.onap.dmaap.mr.client.MRClientFactory;
+import org.onap.dmaap.mr.client.MRClientBuilders.PublisherBuilder;
+import org.onap.dmaap.mr.client.MRPublisher.message;
 
 public class SamplePublisher {
 	public static void main ( String[] args ) throws IOException, InterruptedException
diff --git a/src/main/java/com/att/nsa/mr/test/clients/SimpleExampleConsumer.java b/src/main/java/org/onap/dmaap/mr/test/clients/SimpleExampleConsumer.java
similarity index 95%
rename from src/main/java/com/att/nsa/mr/test/clients/SimpleExampleConsumer.java
rename to src/main/java/org/onap/dmaap/mr/test/clients/SimpleExampleConsumer.java
index 0e3ee5a..a7f283c 100644
--- a/src/main/java/com/att/nsa/mr/test/clients/SimpleExampleConsumer.java
+++ b/src/main/java/org/onap/dmaap/mr/test/clients/SimpleExampleConsumer.java
@@ -20,7 +20,7 @@
  *  
  *******************************************************************************/
 
-package com.att.nsa.mr.test.clients;
+package org.onap.dmaap.mr.test.clients;
 
 import java.io.File;
 import java.io.FileReader;
@@ -30,8 +30,8 @@
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import com.att.nsa.mr.client.MRClientFactory;
-import com.att.nsa.mr.client.MRConsumer;
+import org.onap.dmaap.mr.client.MRClientFactory;
+import org.onap.dmaap.mr.client.MRConsumer;
 
 public class SimpleExampleConsumer {
 
diff --git a/src/main/java/com/att/nsa/mr/test/clients/SimpleExampleConsumerWithReturnResponse.java b/src/main/java/org/onap/dmaap/mr/test/clients/SimpleExampleConsumerWithReturnResponse.java
similarity index 94%
rename from src/main/java/com/att/nsa/mr/test/clients/SimpleExampleConsumerWithReturnResponse.java
rename to src/main/java/org/onap/dmaap/mr/test/clients/SimpleExampleConsumerWithReturnResponse.java
index 433ab9f..2e514b0 100644
--- a/src/main/java/com/att/nsa/mr/test/clients/SimpleExampleConsumerWithReturnResponse.java
+++ b/src/main/java/org/onap/dmaap/mr/test/clients/SimpleExampleConsumerWithReturnResponse.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.test.clients;
+package org.onap.dmaap.mr.test.clients;
 
 import java.io.File;
 import java.io.FileReader;
@@ -29,9 +29,9 @@
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import com.att.nsa.mr.client.MRClientFactory;
-import com.att.nsa.mr.client.MRConsumer;
-import com.att.nsa.mr.client.response.MRConsumerResponse;
+import org.onap.dmaap.mr.client.MRClientFactory;
+import org.onap.dmaap.mr.client.MRConsumer;
+import org.onap.dmaap.mr.client.response.MRConsumerResponse;
 
 public class SimpleExampleConsumerWithReturnResponse {
 
diff --git a/src/main/java/com/att/nsa/mr/test/clients/SimpleExamplePublisher.java b/src/main/java/org/onap/dmaap/mr/test/clients/SimpleExamplePublisher.java
similarity index 93%
rename from src/main/java/com/att/nsa/mr/test/clients/SimpleExamplePublisher.java
rename to src/main/java/org/onap/dmaap/mr/test/clients/SimpleExamplePublisher.java
index 8a6c586..770d916 100644
--- a/src/main/java/com/att/nsa/mr/test/clients/SimpleExamplePublisher.java
+++ b/src/main/java/org/onap/dmaap/mr/test/clients/SimpleExamplePublisher.java
@@ -20,7 +20,7 @@
  *  
  *******************************************************************************/
 
-package com.att.nsa.mr.test.clients;
+package org.onap.dmaap.mr.test.clients;
 
 import java.io.File;
 import java.io.FileReader;
@@ -33,9 +33,9 @@
 
 import org.json.JSONObject;
 
-import com.att.nsa.mr.client.MRBatchingPublisher;
-import com.att.nsa.mr.client.MRClientFactory;
-import com.att.nsa.mr.client.MRPublisher.message;
+import org.onap.dmaap.mr.client.MRBatchingPublisher;
+import org.onap.dmaap.mr.client.MRClientFactory;
+import org.onap.dmaap.mr.client.MRPublisher.message;
 
 /**
  * An example of how to use the Java publisher. 
diff --git a/src/main/java/com/att/nsa/mr/test/clients/SimpleExamplePublisherWithResponse.java b/src/main/java/org/onap/dmaap/mr/test/clients/SimpleExamplePublisherWithResponse.java
similarity index 93%
rename from src/main/java/com/att/nsa/mr/test/clients/SimpleExamplePublisherWithResponse.java
rename to src/main/java/org/onap/dmaap/mr/test/clients/SimpleExamplePublisherWithResponse.java
index 9d179b2..33d1164 100644
--- a/src/main/java/com/att/nsa/mr/test/clients/SimpleExamplePublisherWithResponse.java
+++ b/src/main/java/org/onap/dmaap/mr/test/clients/SimpleExamplePublisherWithResponse.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.test.clients;
+package org.onap.dmaap.mr.test.clients;
 import java.io.File;
 import java.io.FileReader;
 import java.io.FileWriter;
@@ -28,9 +28,9 @@
 import java.util.Properties;
 import java.util.concurrent.TimeUnit;
 import org.json.JSONObject;
-import com.att.nsa.mr.client.MRBatchingPublisher;
-import com.att.nsa.mr.client.MRClientFactory;
-import com.att.nsa.mr.client.response.MRPublisherResponse;
+import org.onap.dmaap.mr.client.MRBatchingPublisher;
+import org.onap.dmaap.mr.client.MRClientFactory;
+import org.onap.dmaap.mr.client.response.MRPublisherResponse;
 	/**
 	 *An example of how to use the Java publisher. 
 	 * @author author
diff --git a/src/main/java/com/att/nsa/mr/test/support/MRBatchingPublisherMock.java b/src/main/java/org/onap/dmaap/mr/test/support/MRBatchingPublisherMock.java
similarity index 95%
rename from src/main/java/com/att/nsa/mr/test/support/MRBatchingPublisherMock.java
rename to src/main/java/org/onap/dmaap/mr/test/support/MRBatchingPublisherMock.java
index 56bec36..3e64c35 100644
--- a/src/main/java/com/att/nsa/mr/test/support/MRBatchingPublisherMock.java
+++ b/src/main/java/org/onap/dmaap/mr/test/support/MRBatchingPublisherMock.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.test.support;
+package org.onap.dmaap.mr.test.support;
 
 import java.util.Collection;
 import java.util.LinkedList;
@@ -28,8 +28,8 @@
 
 import org.slf4j.Logger;
 
-import com.att.nsa.mr.client.MRBatchingPublisher;
-import com.att.nsa.mr.client.response.MRPublisherResponse;
+import org.onap.dmaap.mr.client.MRBatchingPublisher;
+import org.onap.dmaap.mr.client.response.MRPublisherResponse;
 
 /**
  * A helper for unit testing systems that use a MRPublisher. When setting
diff --git a/src/main/java/com/att/nsa/mr/test/support/MRConsumerMock.java b/src/main/java/org/onap/dmaap/mr/test/support/MRConsumerMock.java
similarity index 96%
rename from src/main/java/com/att/nsa/mr/test/support/MRConsumerMock.java
rename to src/main/java/org/onap/dmaap/mr/test/support/MRConsumerMock.java
index c731030..afa36ea 100644
--- a/src/main/java/com/att/nsa/mr/test/support/MRConsumerMock.java
+++ b/src/main/java/org/onap/dmaap/mr/test/support/MRConsumerMock.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.test.support;
+package org.onap.dmaap.mr.test.support;
 
 import java.io.IOException;
 import java.util.LinkedList;
@@ -27,8 +27,8 @@
 
 import org.slf4j.Logger;
 
-import com.att.nsa.mr.client.MRConsumer;
-import com.att.nsa.mr.client.response.MRConsumerResponse;
+import org.onap.dmaap.mr.client.MRConsumer;
+import org.onap.dmaap.mr.client.response.MRConsumerResponse;
 
 /**
  * A helper for unit testing systems that use a MRConsumer. When setting
diff --git a/src/main/java/com/att/nsa/mr/tools/ApiKeyCommand.java b/src/main/java/org/onap/dmaap/mr/tools/ApiKeyCommand.java
similarity index 94%
rename from src/main/java/com/att/nsa/mr/tools/ApiKeyCommand.java
rename to src/main/java/org/onap/dmaap/mr/tools/ApiKeyCommand.java
index df28fc0..a2396d8 100644
--- a/src/main/java/com/att/nsa/mr/tools/ApiKeyCommand.java
+++ b/src/main/java/org/onap/dmaap/mr/tools/ApiKeyCommand.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.tools;
+package org.onap.dmaap.mr.tools;
 
 import java.io.IOException;
 import java.io.PrintStream;
@@ -32,10 +32,10 @@
 import com.att.nsa.apiClient.http.HttpObjectNotFoundException;
 import com.att.nsa.cmdtool.Command;
 import com.att.nsa.cmdtool.CommandNotReadyException;
-import com.att.nsa.mr.client.MRClientFactory;
-import com.att.nsa.mr.client.MRIdentityManager;
-import com.att.nsa.mr.client.MRClient.MRApiException;
-import com.att.nsa.mr.client.MRIdentityManager.ApiKey;
+import org.onap.dmaap.mr.client.MRClientFactory;
+import org.onap.dmaap.mr.client.MRIdentityManager;
+import org.onap.dmaap.mr.client.MRClient.MRApiException;
+import org.onap.dmaap.mr.client.MRIdentityManager.ApiKey;
 
 public class ApiKeyCommand implements Command<MRCommandContext>
 {
diff --git a/src/main/java/com/att/nsa/mr/tools/AuthCommand.java b/src/main/java/org/onap/dmaap/mr/tools/AuthCommand.java
similarity index 98%
rename from src/main/java/com/att/nsa/mr/tools/AuthCommand.java
rename to src/main/java/org/onap/dmaap/mr/tools/AuthCommand.java
index 72f226b..26a70f0 100644
--- a/src/main/java/com/att/nsa/mr/tools/AuthCommand.java
+++ b/src/main/java/org/onap/dmaap/mr/tools/AuthCommand.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.tools;
+package org.onap.dmaap.mr.tools;
 
 import java.io.PrintStream;
 
diff --git a/src/main/java/com/att/nsa/mr/tools/ClusterCommand.java b/src/main/java/org/onap/dmaap/mr/tools/ClusterCommand.java
similarity index 96%
rename from src/main/java/com/att/nsa/mr/tools/ClusterCommand.java
rename to src/main/java/org/onap/dmaap/mr/tools/ClusterCommand.java
index 5ecaf7c..c4ef5e4 100644
--- a/src/main/java/com/att/nsa/mr/tools/ClusterCommand.java
+++ b/src/main/java/org/onap/dmaap/mr/tools/ClusterCommand.java
@@ -19,13 +19,13 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.tools;
+package org.onap.dmaap.mr.tools;
 
 import java.io.PrintStream;
 
 import com.att.nsa.cmdtool.Command;
 import com.att.nsa.cmdtool.CommandNotReadyException;
-import com.att.nsa.mr.client.impl.MRConsumerImpl;
+import org.onap.dmaap.mr.client.impl.MRConsumerImpl;
 
 public class ClusterCommand implements Command<MRCommandContext>
 {
diff --git a/src/main/java/com/att/nsa/mr/tools/MRCommandContext.java b/src/main/java/org/onap/dmaap/mr/tools/MRCommandContext.java
similarity index 96%
rename from src/main/java/com/att/nsa/mr/tools/MRCommandContext.java
rename to src/main/java/org/onap/dmaap/mr/tools/MRCommandContext.java
index e512769..5d13b30 100644
--- a/src/main/java/com/att/nsa/mr/tools/MRCommandContext.java
+++ b/src/main/java/org/onap/dmaap/mr/tools/MRCommandContext.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.tools;
+package org.onap.dmaap.mr.tools;
 
 import java.util.Collection;
 import java.util.LinkedList;
@@ -27,7 +27,7 @@
 import com.att.nsa.apiClient.http.HttpClient;
 import com.att.nsa.apiClient.http.HttpTracer;
 import com.att.nsa.cmdtool.CommandContext;
-import com.att.nsa.mr.client.MRClient;
+import org.onap.dmaap.mr.client.MRClient;
 
 public class MRCommandContext implements CommandContext
 {
diff --git a/src/main/java/com/att/nsa/mr/tools/MRTool.java b/src/main/java/org/onap/dmaap/mr/tools/MRTool.java
similarity index 95%
rename from src/main/java/com/att/nsa/mr/tools/MRTool.java
rename to src/main/java/org/onap/dmaap/mr/tools/MRTool.java
index 7f1effd..a37fa79 100644
--- a/src/main/java/com/att/nsa/mr/tools/MRTool.java
+++ b/src/main/java/org/onap/dmaap/mr/tools/MRTool.java
@@ -19,12 +19,12 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.tools;
+package org.onap.dmaap.mr.tools;
 
 import java.io.IOException;
 
 import com.att.nsa.cmdtool.CommandLineTool;
-import com.att.nsa.mr.client.impl.MRClientVersionInfo;
+import org.onap.dmaap.mr.client.impl.MRClientVersionInfo;
 
 public class MRTool extends CommandLineTool<MRCommandContext>
 {
diff --git a/src/main/java/com/att/nsa/mr/tools/MessageCommand.java b/src/main/java/org/onap/dmaap/mr/tools/MessageCommand.java
similarity index 92%
rename from src/main/java/com/att/nsa/mr/tools/MessageCommand.java
rename to src/main/java/org/onap/dmaap/mr/tools/MessageCommand.java
index 54e92ae..5016c95 100644
--- a/src/main/java/com/att/nsa/mr/tools/MessageCommand.java
+++ b/src/main/java/org/onap/dmaap/mr/tools/MessageCommand.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.tools;
+package org.onap.dmaap.mr.tools;
 
 import java.io.IOException;
 import java.io.PrintStream;
@@ -31,11 +31,11 @@
 
 import com.att.nsa.cmdtool.Command;
 import com.att.nsa.cmdtool.CommandNotReadyException;
-import com.att.nsa.mr.client.MRBatchingPublisher;
-import com.att.nsa.mr.client.MRClientFactory;
-import com.att.nsa.mr.client.MRConsumer;
-import com.att.nsa.mr.client.MRClientBuilders.PublisherBuilder;
-import com.att.nsa.mr.client.MRPublisher.message;
+import org.onap.dmaap.mr.client.MRBatchingPublisher;
+import org.onap.dmaap.mr.client.MRClientFactory;
+import org.onap.dmaap.mr.client.MRConsumer;
+import org.onap.dmaap.mr.client.MRClientBuilders.PublisherBuilder;
+import org.onap.dmaap.mr.client.MRPublisher.message;
 
 public class MessageCommand implements Command<MRCommandContext>
 {
diff --git a/src/main/java/com/att/nsa/mr/tools/ToolsUtil.java b/src/main/java/org/onap/dmaap/mr/tools/ToolsUtil.java
similarity index 89%
rename from src/main/java/com/att/nsa/mr/tools/ToolsUtil.java
rename to src/main/java/org/onap/dmaap/mr/tools/ToolsUtil.java
index 45b21d1..72e7fbf 100644
--- a/src/main/java/com/att/nsa/mr/tools/ToolsUtil.java
+++ b/src/main/java/org/onap/dmaap/mr/tools/ToolsUtil.java
@@ -18,10 +18,10 @@
  * ============LICENSE_END=========================================================
  */
 
-package com.att.nsa.mr.tools;
+package org.onap.dmaap.mr.tools;
 
-import com.att.nsa.mr.client.MRBatchingPublisher;
-import com.att.nsa.mr.client.MRClientBuilders.PublisherBuilder;
+import org.onap.dmaap.mr.client.MRBatchingPublisher;
+import org.onap.dmaap.mr.client.MRClientBuilders.PublisherBuilder;
 
 public final class ToolsUtil {
 
diff --git a/src/main/java/com/att/nsa/mr/tools/TopicCommand.java b/src/main/java/org/onap/dmaap/mr/tools/TopicCommand.java
similarity index 96%
rename from src/main/java/com/att/nsa/mr/tools/TopicCommand.java
rename to src/main/java/org/onap/dmaap/mr/tools/TopicCommand.java
index 4b1151e..278b04f 100644
--- a/src/main/java/com/att/nsa/mr/tools/TopicCommand.java
+++ b/src/main/java/org/onap/dmaap/mr/tools/TopicCommand.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.tools;
+package org.onap.dmaap.mr.tools;
 
 import java.io.IOException;
 import java.io.PrintStream;
@@ -32,9 +32,9 @@
 import com.att.nsa.apiClient.http.HttpObjectNotFoundException;
 import com.att.nsa.cmdtool.Command;
 import com.att.nsa.cmdtool.CommandNotReadyException;
-import com.att.nsa.mr.client.MRClientFactory;
-import com.att.nsa.mr.client.MRTopicManager;
-import com.att.nsa.mr.client.MRTopicManager.TopicInfo;
+import org.onap.dmaap.mr.client.MRClientFactory;
+import org.onap.dmaap.mr.client.MRTopicManager;
+import org.onap.dmaap.mr.client.MRTopicManager.TopicInfo;
 
 public class TopicCommand implements Command<MRCommandContext>
 {
diff --git a/src/main/java/com/att/nsa/mr/tools/TraceCommand.java b/src/main/java/org/onap/dmaap/mr/tools/TraceCommand.java
similarity index 98%
rename from src/main/java/com/att/nsa/mr/tools/TraceCommand.java
rename to src/main/java/org/onap/dmaap/mr/tools/TraceCommand.java
index 0489172..95edf5b 100644
--- a/src/main/java/com/att/nsa/mr/tools/TraceCommand.java
+++ b/src/main/java/org/onap/dmaap/mr/tools/TraceCommand.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.tools;
+package org.onap.dmaap.mr.tools;
 
 import java.io.PrintStream;
 import java.net.URI;
diff --git a/src/main/java/com/att/nsa/mr/tools/ValidatorUtil.java b/src/main/java/org/onap/dmaap/mr/tools/ValidatorUtil.java
similarity index 98%
rename from src/main/java/com/att/nsa/mr/tools/ValidatorUtil.java
rename to src/main/java/org/onap/dmaap/mr/tools/ValidatorUtil.java
index 0539582..cdba1e0 100644
--- a/src/main/java/com/att/nsa/mr/tools/ValidatorUtil.java
+++ b/src/main/java/org/onap/dmaap/mr/tools/ValidatorUtil.java
@@ -19,11 +19,11 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.tools;
+package org.onap.dmaap.mr.tools;
 
 import java.util.Properties;
 
-import com.att.nsa.mr.test.clients.ProtocolTypeConstants;
+import org.onap.dmaap.mr.test.clients.ProtocolTypeConstants;
 
 public class ValidatorUtil {
 
diff --git a/src/test/java/com/att/nsa/mr/client/TestRunner.java b/src/test/java/com/att/nsa/mr/client/TestRunner.java
deleted file mode 100644
index 814354c..0000000
--- a/src/test/java/com/att/nsa/mr/client/TestRunner.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.client;
-
-import org.junit.runner.JUnitCore;
-import org.junit.runner.Result;
-import org.junit.runner.notification.Failure;
-import org.apache.log4j.Logger;
-
-public class TestRunner {
-	private static final Logger LOGGER = Logger.getLogger(TestRunner.class);
-
-	public static void main(String[] args) {
-		// TODO Auto-generated method stub
-		Result result = JUnitCore.runClasses(JUnitTestSuite.class);
-		for (Failure failure : result.getFailures()) {
-			LOGGER.info(failure.toString());
-			
-		}
-		LOGGER.info(result.wasSuccessful());
-	}
-
-}
diff --git a/src/test/java/com/att/nsa/mr/client/response/TestRunner.java b/src/test/java/com/att/nsa/mr/client/response/TestRunner.java
deleted file mode 100644
index f2abadc..0000000
--- a/src/test/java/com/att/nsa/mr/client/response/TestRunner.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.client.response;
-
-import org.junit.runner.JUnitCore;
-import org.junit.runner.Result;
-import org.junit.runner.notification.Failure;
-import org.apache.log4j.Logger;
-
-public class TestRunner {
-	private static final Logger LOGGER = Logger.getLogger(TestRunner.class);
-
-	public static void main(String[] args) {
-		// TODO Auto-generated method stub
-		Result result = JUnitCore.runClasses(JUnitTestSuite.class);
-		for (Failure failure : result.getFailures()) {
-			LOGGER.info(failure.toString());
-			
-		}
-		LOGGER.info(result.wasSuccessful());
-	}
-
-}
diff --git a/src/test/java/com/att/nsa/mr/logging/TestRunner.java b/src/test/java/com/att/nsa/mr/logging/TestRunner.java
deleted file mode 100644
index 415156f..0000000
--- a/src/test/java/com/att/nsa/mr/logging/TestRunner.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.logging;
-
-import org.junit.runner.JUnitCore;
-import org.junit.runner.Result;
-import org.junit.runner.notification.Failure;
-import org.apache.log4j.Logger;
-
-public class TestRunner {
-	private static final Logger LOGGER = Logger.getLogger(TestRunner.class);
-
-	public static void main(String[] args) {
-		// TODO Auto-generated method stub
-		Result result = JUnitCore.runClasses(JUnitTestSuite.class);
-		for (Failure failure : result.getFailures()) {
-			LOGGER.info(failure.toString());
-			
-		}
-		LOGGER.info(result.wasSuccessful());
-	}
-
-}
diff --git a/src/test/java/com/att/nsa/mr/test/clients/TestRunner.java b/src/test/java/com/att/nsa/mr/test/clients/TestRunner.java
deleted file mode 100644
index 39bbbb3..0000000
--- a/src/test/java/com/att/nsa/mr/test/clients/TestRunner.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.test.clients;
-
-import org.junit.runner.JUnitCore;
-import org.junit.runner.Result;
-import org.junit.runner.notification.Failure;
-import org.apache.log4j.Logger;
-
-public class TestRunner {
-	private static final Logger LOGGER = Logger.getLogger(TestRunner.class);
-
-	public static void main(String[] args) {
-		// TODO Auto-generated method stub
-		Result result = JUnitCore.runClasses(JUnitTestSuite.class);
-		for (Failure failure : result.getFailures()) {
-			LOGGER.info(failure.toString());
-			
-		}
-		LOGGER.info(result.wasSuccessful());
-	}
-
-}
diff --git a/src/test/java/com/att/nsa/mr/test/support/TestRunner.java b/src/test/java/com/att/nsa/mr/test/support/TestRunner.java
deleted file mode 100644
index 4e8651c..0000000
--- a/src/test/java/com/att/nsa/mr/test/support/TestRunner.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.test.support;
-
-import org.junit.runner.JUnitCore;
-import org.junit.runner.Result;
-import org.junit.runner.notification.Failure;
-import org.apache.log4j.Logger;
-
-public class TestRunner {
-	private static final Logger LOGGER = Logger.getLogger(TestRunner.class);
-
-	public static void main(String[] args) {
-		// TODO Auto-generated method stub
-		Result result = JUnitCore.runClasses(JUnitTestSuite.class);
-		for (Failure failure : result.getFailures()) {
-			LOGGER.info(failure.toString());
-			
-		}
-		LOGGER.info(result.wasSuccessful());
-	}
-
-}
diff --git a/src/test/java/com/att/nsa/mr/tools/TestRunner.java b/src/test/java/com/att/nsa/mr/tools/TestRunner.java
deleted file mode 100644
index 728752b..0000000
--- a/src/test/java/com/att/nsa/mr/tools/TestRunner.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.tools;
-
-import org.junit.runner.JUnitCore;
-import org.junit.runner.Result;
-import org.junit.runner.notification.Failure;
-import org.apache.log4j.Logger;
-
-public class TestRunner {
-	private static final Logger LOGGER = Logger.getLogger(TestRunner.class);
-
-	public static void main(String[] args) {
-		// TODO Auto-generated method stub
-		Result result = JUnitCore.runClasses(JUnitTestSuite.class);
-		for (Failure failure : result.getFailures()) {
-			LOGGER.info(failure.toString());
-			
-		}
-		LOGGER.info(result.wasSuccessful());
-	}
-
-}
diff --git a/src/test/java/com/att/nsa/mr/client/HostSelectorTest.java b/src/test/java/org/onap/dmaap/mr/client/HostSelectorTest.java
similarity index 95%
rename from src/test/java/com/att/nsa/mr/client/HostSelectorTest.java
rename to src/test/java/org/onap/dmaap/mr/client/HostSelectorTest.java
index fd6dee8..ecc4b51 100644
--- a/src/test/java/com/att/nsa/mr/client/HostSelectorTest.java
+++ b/src/test/java/org/onap/dmaap/mr/client/HostSelectorTest.java
@@ -1,68 +1,68 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.client;
-
-import static org.junit.Assert.assertTrue;
-
-import java.util.concurrent.TimeUnit;
-
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-
-import com.att.nsa.mr.client.HostSelector;
-
-public class HostSelectorTest {
-	
-	@Before
-	public void setUp() throws Exception {
-		
-	}
-
-	@After
-	public void tearDown() throws Exception {
-		
-	}
-
-	
-	@Test
-	public void testSelectBaseHost() {
-		
-		HostSelector selector = new HostSelector("host");
-				
-		selector.selectBaseHost();
-		assertTrue(true);
-		
-
-	}
-
-	@Test
-	public void testReportReachabilityProblem() {
-		
-		HostSelector selector = new HostSelector("host");
-				
-		selector.reportReachabilityProblem(100, null);
-		assertTrue(true);
-		
-
-	}
-}
-
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.client;
+
+import static org.junit.Assert.assertTrue;
+
+import java.util.concurrent.TimeUnit;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+
+import org.onap.dmaap.mr.client.HostSelector;
+
+public class HostSelectorTest {
+	
+	@Before
+	public void setUp() throws Exception {
+		
+	}
+
+	@After
+	public void tearDown() throws Exception {
+		
+	}
+
+	
+	@Test
+	public void testSelectBaseHost() {
+		
+		HostSelector selector = new HostSelector("host");
+				
+		selector.selectBaseHost();
+		assertTrue(true);
+		
+
+	}
+
+	@Test
+	public void testReportReachabilityProblem() {
+		
+		HostSelector selector = new HostSelector("host");
+				
+		selector.reportReachabilityProblem(100, null);
+		assertTrue(true);
+		
+
+	}
+}
+
diff --git a/src/test/java/com/att/nsa/mr/client/JUnitTestSuite.java b/src/test/java/org/onap/dmaap/mr/client/JUnitTestSuite.java
similarity index 97%
rename from src/test/java/com/att/nsa/mr/client/JUnitTestSuite.java
rename to src/test/java/org/onap/dmaap/mr/client/JUnitTestSuite.java
index 095e1d8..b791b51 100644
--- a/src/test/java/com/att/nsa/mr/client/JUnitTestSuite.java
+++ b/src/test/java/org/onap/dmaap/mr/client/JUnitTestSuite.java
@@ -1,43 +1,43 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.client;
-
-import junit.framework.TestSuite;
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-import org.junit.runners.Suite.SuiteClasses;
-import org.apache.log4j.Logger;
-
-@RunWith(Suite.class)
-@SuiteClasses({ HostSelectorTest.class, MRClientBuildersTest.class, MRClientFactoryTest.class})
-
-public class JUnitTestSuite {
-	private static final Logger LOGGER = Logger.getLogger(JUnitTestSuite.class);
-
-	public static void main(String[] args) {
-		LOGGER.info("Running the test suite");
-		
-		TestSuite tstSuite = new TestSuite();
-		LOGGER.info("Total Test Counts " + tstSuite.countTestCases());
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.client;
+
+import junit.framework.TestSuite;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Suite;
+import org.junit.runners.Suite.SuiteClasses;
+import org.apache.log4j.Logger;
+
+@RunWith(Suite.class)
+@SuiteClasses({ HostSelectorTest.class, MRClientBuildersTest.class, MRClientFactoryTest.class})
+
+public class JUnitTestSuite {
+	private static final Logger LOGGER = Logger.getLogger(JUnitTestSuite.class);
+
+	public static void main(String[] args) {
+		LOGGER.info("Running the test suite");
+		
+		TestSuite tstSuite = new TestSuite();
+		LOGGER.info("Total Test Counts " + tstSuite.countTestCases());
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/client/MRClientBuildersTest.java b/src/test/java/org/onap/dmaap/mr/client/MRClientBuildersTest.java
similarity index 96%
rename from src/test/java/com/att/nsa/mr/client/MRClientBuildersTest.java
rename to src/test/java/org/onap/dmaap/mr/client/MRClientBuildersTest.java
index 9a0a3ce..388a91c 100644
--- a/src/test/java/com/att/nsa/mr/client/MRClientBuildersTest.java
+++ b/src/test/java/org/onap/dmaap/mr/client/MRClientBuildersTest.java
@@ -1,248 +1,248 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
- * ================================================================================
- *  Modifications Copyright © 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
- * 
- *      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 com.att.nsa.mr.client;
-
-import static org.junit.Assert.assertTrue;
-
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.concurrent.TimeUnit;
-
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-
-import com.att.nsa.mr.client.HostSelector;
-import com.att.nsa.mr.client.MRClient;
-import com.att.nsa.mr.client.MRClientBuilders;
-
-public class MRClientBuildersTest {
-
-    private Collection<String> hostSet = new ArrayList<String>();
-    private MRClientBuilders.ConsumerBuilder builder = null;
-    private MRClientBuilders.PublisherBuilder pBuilder = null;
-    private String[] hostArray = new String[10];
-
-    @Before
-    public void setUp() throws Exception {
-
-        for (int i = 0; i < 10; i++) {
-            hostSet.add("host" + (i + 1));
-            hostArray[i] = "host" + (i + 1);
-        }
-
-        builder = new MRClientBuilders.ConsumerBuilder();
-
-        pBuilder = new MRClientBuilders.PublisherBuilder();
-
-    }
-
-    @After
-    public void tearDown() throws Exception {
-
-    }
-
-    @Test
-    public void testUsingHosts() {
-
-        builder.usingHosts("hostList");
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testUsingHosts2() {
-
-        builder.usingHosts(hostSet);
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testOnTopic() {
-
-        builder.onTopic("testTopic");
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testKnownAs() {
-
-        builder.knownAs("CG1", "23");
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testAuthenticatedBy() {
-
-        builder.authenticatedBy("apikey", "apisecret");
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testWaitAtServer() {
-
-        builder.waitAtServer(100);
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testReceivingAtMost() {
-
-        builder.receivingAtMost(100);
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testWithServerSideFilter() {
-
-        builder.withServerSideFilter("filter");
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testBuild() {
-
-        try {
-
-            builder.build();
-        } catch (IllegalArgumentException e) {
-            assertTrue(true);
-        }
-
-    }
-
-    @Test
-    public void testUsingHosts3() {
-
-        pBuilder.usingHosts("testTopic");
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testUsingHosts4() {
-
-        pBuilder.usingHosts(hostArray);
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testUsingHosts5() {
-
-        pBuilder.usingHosts(hostSet);
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testOnTopic2() {
-
-        pBuilder.onTopic("testTopic");
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testLimitBatch() {
-
-        pBuilder.limitBatch(100, 10);
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testWithCompresion() {
-
-        pBuilder.withCompresion();
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testWithoutCompresion() {
-
-        pBuilder.withoutCompresion();
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testEnableCompresion() {
-
-        pBuilder.enableCompresion(true);
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testAuthenticatedBy2() {
-
-        pBuilder.authenticatedBy("apikey", "apisecret");
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testBuild2() {
-
-        try {
-
-            pBuilder.build();
-        } catch (IllegalArgumentException e) {
-            assertTrue(true);
-        }
-
-    }
-
-    @Test
-    public void test$testInject() {
-
-        try {
-
-            MRClientBuilders.$testInject(builder.build());
-        } catch (IllegalArgumentException e) {
-            assertTrue(true);
-        }
-
-    }
-
-    @Test
-    public void test$testInject2() {
-
-        try {
-
-            MRClientBuilders.$testInject(pBuilder.build());
-        } catch (IllegalArgumentException e) {
-            assertTrue(true);
-        }
-
-    }
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ *  Modifications Copyright © 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
+ * 
+ *      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.dmaap.mr.client;
+
+import static org.junit.Assert.assertTrue;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.concurrent.TimeUnit;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+
+import org.onap.dmaap.mr.client.HostSelector;
+import org.onap.dmaap.mr.client.MRClient;
+import org.onap.dmaap.mr.client.MRClientBuilders;
+
+public class MRClientBuildersTest {
+
+    private Collection<String> hostSet = new ArrayList<String>();
+    private MRClientBuilders.ConsumerBuilder builder = null;
+    private MRClientBuilders.PublisherBuilder pBuilder = null;
+    private String[] hostArray = new String[10];
+
+    @Before
+    public void setUp() throws Exception {
+
+        for (int i = 0; i < 10; i++) {
+            hostSet.add("host" + (i + 1));
+            hostArray[i] = "host" + (i + 1);
+        }
+
+        builder = new MRClientBuilders.ConsumerBuilder();
+
+        pBuilder = new MRClientBuilders.PublisherBuilder();
+
+    }
+
+    @After
+    public void tearDown() throws Exception {
+
+    }
+
+    @Test
+    public void testUsingHosts() {
+
+        builder.usingHosts("hostList");
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testUsingHosts2() {
+
+        builder.usingHosts(hostSet);
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testOnTopic() {
+
+        builder.onTopic("testTopic");
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testKnownAs() {
+
+        builder.knownAs("CG1", "23");
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testAuthenticatedBy() {
+
+        builder.authenticatedBy("apikey", "apisecret");
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testWaitAtServer() {
+
+        builder.waitAtServer(100);
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testReceivingAtMost() {
+
+        builder.receivingAtMost(100);
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testWithServerSideFilter() {
+
+        builder.withServerSideFilter("filter");
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testBuild() {
+
+        try {
+
+            builder.build();
+        } catch (IllegalArgumentException e) {
+            assertTrue(true);
+        }
+
+    }
+
+    @Test
+    public void testUsingHosts3() {
+
+        pBuilder.usingHosts("testTopic");
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testUsingHosts4() {
+
+        pBuilder.usingHosts(hostArray);
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testUsingHosts5() {
+
+        pBuilder.usingHosts(hostSet);
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testOnTopic2() {
+
+        pBuilder.onTopic("testTopic");
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testLimitBatch() {
+
+        pBuilder.limitBatch(100, 10);
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testWithCompresion() {
+
+        pBuilder.withCompresion();
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testWithoutCompresion() {
+
+        pBuilder.withoutCompresion();
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testEnableCompresion() {
+
+        pBuilder.enableCompresion(true);
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testAuthenticatedBy2() {
+
+        pBuilder.authenticatedBy("apikey", "apisecret");
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testBuild2() {
+
+        try {
+
+            pBuilder.build();
+        } catch (IllegalArgumentException e) {
+            assertTrue(true);
+        }
+
+    }
+
+    @Test
+    public void test$testInject() {
+
+        try {
+
+            MRClientBuilders.$testInject(builder.build());
+        } catch (IllegalArgumentException e) {
+            assertTrue(true);
+        }
+
+    }
+
+    @Test
+    public void test$testInject2() {
+
+        try {
+
+            MRClientBuilders.$testInject(pBuilder.build());
+        } catch (IllegalArgumentException e) {
+            assertTrue(true);
+        }
+
+    }
+}
diff --git a/src/test/java/com/att/nsa/mr/client/MRClientFactoryTest.java b/src/test/java/org/onap/dmaap/mr/client/MRClientFactoryTest.java
similarity index 96%
rename from src/test/java/com/att/nsa/mr/client/MRClientFactoryTest.java
rename to src/test/java/org/onap/dmaap/mr/client/MRClientFactoryTest.java
index 7ea091b..0d151b9 100644
--- a/src/test/java/com/att/nsa/mr/client/MRClientFactoryTest.java
+++ b/src/test/java/org/onap/dmaap/mr/client/MRClientFactoryTest.java
@@ -1,252 +1,252 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
- * ================================================================================
- *  Modifications Copyright © 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
- * 
- *      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 com.att.nsa.mr.client;
-
-import static org.junit.Assert.assertTrue;
-
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.concurrent.TimeUnit;
-
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-
-import com.att.nsa.mr.client.HostSelector;
-import com.att.nsa.mr.client.MRClient;
-import com.att.nsa.mr.client.MRClientBuilders;
-import com.att.nsa.mr.client.MRClientFactory;
-
-public class MRClientFactoryTest {
-
-    private Collection<String> hostSet = new ArrayList<String>();
-
-    private String[] hostArray = new String[10];
-
-    @Before
-    public void setUp() throws Exception {
-
-        for (int i = 0; i < 10; i++) {
-            hostSet.add("host" + (i + 1));
-            hostArray[i] = "host" + (i + 1);
-        }
-    }
-
-    @After
-    public void tearDown() throws Exception {
-
-    }
-
-    @Test
-    public void testCreateConsumer() {
-
-        MRClientFactory.createConsumer("hostList hostList2", "testTopic");
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testCreateConsumer2() {
-
-        MRClientFactory.createConsumer(hostSet, "testTopic");
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testCreateConsumer3() {
-
-        MRClientFactory.createConsumer(hostSet, "testTopic", "filter");
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testCreateConsumer4() {
-
-        MRClientFactory.createConsumer(hostSet, "testTopic", "CG1", "22");
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testCreateConsumer5() {
-
-        MRClientFactory.createConsumer(hostSet, "testTopic", "CG1", "22", 100, 100);
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testCreateConsumer6() {
-
-        MRClientFactory.createConsumer("hostList", "testTopic", "CG1", "22", 100, 100, "filter", "apikey", "apisecret");
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testCreateConsumer7() {
-
-        MRClientFactory.createConsumer(hostSet, "testTopic", "CG1", "22", 100, 100, "filter", "apikey", "apisecret");
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testCreateSimplePublisher() {
-
-        MRClientFactory.createSimplePublisher("hostList", "testTopic");
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testCreateBatchingPublisher1() {
-
-        MRClientFactory.createBatchingPublisher("hostList", "testTopic", 100, 10);
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testCreateBatchingPublisher2() {
-
-        MRClientFactory.createBatchingPublisher("hostList", "testTopic", 100, 10, true);
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testCreateBatchingPublisher3() {
-
-        MRClientFactory.createBatchingPublisher(hostArray, "testTopic", 100, 10, true);
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testCreateBatchingPublisher4() {
-
-    MRClientFactory.createBatchingPublisher(hostSet, "testTopic", 100, 10, true);
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testCreateBatchingPublisher5() {
-
-        MRClientFactory.createBatchingPublisher("host", "testTopic", "username", "password", 100, 10, true,
-                "protocolFlag");
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testCreateBatchingPublisher6() {
-
-        try {
-            MRClientFactory.createBatchingPublisher("/producer");
-        } catch (IOException e) {
-            // TODO Auto-generated catch block
-            e.printStackTrace();
-        }
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testCreateBatchingPublisher7() {
-
-        try {
-            MRClientFactory.createBatchingPublisher("/producer", true);
-        } catch (IOException e) {
-            // TODO Auto-generated catch block
-            e.printStackTrace();
-        }
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testCreateIdentityManager() {
-
-        MRClientFactory.createIdentityManager(hostSet, "apikey", "apisecret");
-
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testCreateTopicManager() {
-
-        MRClientFactory.createTopicManager(hostSet, "apikey", "apisecret");
-
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testCreateConsumer8() {
-
-        try {
-            MRClientFactory.createConsumer("/consumer");
-        } catch (IOException e) {
-            // TODO Auto-generated catch block
-            e.printStackTrace();
-        }
-
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testCreateConsumer9() {
-
-        MRClientFactory.createConsumer("host", "topic", "username", "password", "group", "23", "protocolFlag",
-                "/consumer", 1, 2);
-
-        assertTrue(true);
-
-    }
-
-    @Test
-    public void testCreateConsumer10() {
-
-        MRClientFactory.createConsumer("host", "topic", "username", "password", "group", "23", 1, 2, "protocolFlag",
-                "/consumer");
-
-        assertTrue(true);
-
-    }
-    
-    @Test
-    public void test$testInject() {
-
-        MRClientFactory.$testInject(null);
-        assertTrue(true);
-
-    }
-
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ *  Modifications Copyright © 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
+ * 
+ *      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.dmaap.mr.client;
+
+import static org.junit.Assert.assertTrue;
+
+import java.io.IOException;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.concurrent.TimeUnit;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+
+import org.onap.dmaap.mr.client.HostSelector;
+import org.onap.dmaap.mr.client.MRClient;
+import org.onap.dmaap.mr.client.MRClientBuilders;
+import org.onap.dmaap.mr.client.MRClientFactory;
+
+public class MRClientFactoryTest {
+
+    private Collection<String> hostSet = new ArrayList<String>();
+
+    private String[] hostArray = new String[10];
+
+    @Before
+    public void setUp() throws Exception {
+
+        for (int i = 0; i < 10; i++) {
+            hostSet.add("host" + (i + 1));
+            hostArray[i] = "host" + (i + 1);
+        }
+    }
+
+    @After
+    public void tearDown() throws Exception {
+
+    }
+
+    @Test
+    public void testCreateConsumer() {
+
+        MRClientFactory.createConsumer("hostList hostList2", "testTopic");
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testCreateConsumer2() {
+
+        MRClientFactory.createConsumer(hostSet, "testTopic");
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testCreateConsumer3() {
+
+        MRClientFactory.createConsumer(hostSet, "testTopic", "filter");
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testCreateConsumer4() {
+
+        MRClientFactory.createConsumer(hostSet, "testTopic", "CG1", "22");
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testCreateConsumer5() {
+
+        MRClientFactory.createConsumer(hostSet, "testTopic", "CG1", "22", 100, 100);
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testCreateConsumer6() {
+
+        MRClientFactory.createConsumer("hostList", "testTopic", "CG1", "22", 100, 100, "filter", "apikey", "apisecret");
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testCreateConsumer7() {
+
+        MRClientFactory.createConsumer(hostSet, "testTopic", "CG1", "22", 100, 100, "filter", "apikey", "apisecret");
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testCreateSimplePublisher() {
+
+        MRClientFactory.createSimplePublisher("hostList", "testTopic");
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testCreateBatchingPublisher1() {
+
+        MRClientFactory.createBatchingPublisher("hostList", "testTopic", 100, 10);
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testCreateBatchingPublisher2() {
+
+        MRClientFactory.createBatchingPublisher("hostList", "testTopic", 100, 10, true);
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testCreateBatchingPublisher3() {
+
+        MRClientFactory.createBatchingPublisher(hostArray, "testTopic", 100, 10, true);
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testCreateBatchingPublisher4() {
+
+    MRClientFactory.createBatchingPublisher(hostSet, "testTopic", 100, 10, true);
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testCreateBatchingPublisher5() {
+
+        MRClientFactory.createBatchingPublisher("host", "testTopic", "username", "password", 100, 10, true,
+                "protocolFlag");
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testCreateBatchingPublisher6() {
+
+        try {
+            MRClientFactory.createBatchingPublisher("/producer");
+        } catch (IOException e) {
+            // TODO Auto-generated catch block
+            e.printStackTrace();
+        }
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testCreateBatchingPublisher7() {
+
+        try {
+            MRClientFactory.createBatchingPublisher("/producer", true);
+        } catch (IOException e) {
+            // TODO Auto-generated catch block
+            e.printStackTrace();
+        }
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testCreateIdentityManager() {
+
+        MRClientFactory.createIdentityManager(hostSet, "apikey", "apisecret");
+
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testCreateTopicManager() {
+
+        MRClientFactory.createTopicManager(hostSet, "apikey", "apisecret");
+
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testCreateConsumer8() {
+
+        try {
+            MRClientFactory.createConsumer("/consumer");
+        } catch (IOException e) {
+            // TODO Auto-generated catch block
+            e.printStackTrace();
+        }
+
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testCreateConsumer9() {
+
+        MRClientFactory.createConsumer("host", "topic", "username", "password", "group", "23", "protocolFlag",
+                "/consumer", 1, 2);
+
+        assertTrue(true);
+
+    }
+
+    @Test
+    public void testCreateConsumer10() {
+
+        MRClientFactory.createConsumer("host", "topic", "username", "password", "group", "23", 1, 2, "protocolFlag",
+                "/consumer");
+
+        assertTrue(true);
+
+    }
+    
+    @Test
+    public void test$testInject() {
+
+        MRClientFactory.$testInject(null);
+        assertTrue(true);
+
+    }
+
 }
\ No newline at end of file
diff --git a/src/test/java/com/att/nsa/mr/dme/client/TestRunner.java b/src/test/java/org/onap/dmaap/mr/client/TestRunner.java
similarity index 97%
copy from src/test/java/com/att/nsa/mr/dme/client/TestRunner.java
copy to src/test/java/org/onap/dmaap/mr/client/TestRunner.java
index 08be6da..f9b8a86 100644
--- a/src/test/java/com/att/nsa/mr/dme/client/TestRunner.java
+++ b/src/test/java/org/onap/dmaap/mr/client/TestRunner.java
@@ -1,41 +1,41 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.dme.client;
-
-import org.junit.runner.JUnitCore;
-import org.junit.runner.Result;
-import org.junit.runner.notification.Failure;
-import org.apache.log4j.Logger;
-
-public class TestRunner {
-	private static final Logger LOGGER = Logger.getLogger(TestRunner.class);
-
-	public static void main(String[] args) {
-		// TODO Auto-generated method stub
-		Result result = JUnitCore.runClasses(JUnitTestSuite.class);
-		for (Failure failure : result.getFailures()) {
-			LOGGER.info(failure.toString());
-			
-		}
-		LOGGER.info(result.wasSuccessful());
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.client;
+
+import org.junit.runner.JUnitCore;
+import org.junit.runner.Result;
+import org.junit.runner.notification.Failure;
+import org.apache.log4j.Logger;
+
+public class TestRunner {
+	private static final Logger LOGGER = Logger.getLogger(TestRunner.class);
+
+	public static void main(String[] args) {
+		// TODO Auto-generated method stub
+		Result result = JUnitCore.runClasses(JUnitTestSuite.class);
+		for (Failure failure : result.getFailures()) {
+			LOGGER.info(failure.toString());
+			
+		}
+		LOGGER.info(result.wasSuccessful());
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/client/impl/DMaapClientUtilTest.java b/src/test/java/org/onap/dmaap/mr/client/impl/DMaapClientUtilTest.java
similarity index 98%
rename from src/test/java/com/att/nsa/mr/client/impl/DMaapClientUtilTest.java
rename to src/test/java/org/onap/dmaap/mr/client/impl/DMaapClientUtilTest.java
index 9841adb..6fb31a6 100644
--- a/src/test/java/com/att/nsa/mr/client/impl/DMaapClientUtilTest.java
+++ b/src/test/java/org/onap/dmaap/mr/client/impl/DMaapClientUtilTest.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.client.impl;
+package org.onap.dmaap.mr.client.impl;
 
 import static org.junit.Assert.assertEquals;
 
diff --git a/src/test/java/com/att/nsa/mr/client/impl/MRBaseClientTest.java b/src/test/java/org/onap/dmaap/mr/client/impl/MRBaseClientTest.java
similarity index 99%
rename from src/test/java/com/att/nsa/mr/client/impl/MRBaseClientTest.java
rename to src/test/java/org/onap/dmaap/mr/client/impl/MRBaseClientTest.java
index 055c94f..6fe0e70 100644
--- a/src/test/java/com/att/nsa/mr/client/impl/MRBaseClientTest.java
+++ b/src/test/java/org/onap/dmaap/mr/client/impl/MRBaseClientTest.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.client.impl;
+package org.onap.dmaap.mr.client.impl;
 
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertTrue;
diff --git a/src/test/java/com/att/nsa/mr/client/impl/MRBatchPublisherTest.java b/src/test/java/org/onap/dmaap/mr/client/impl/MRBatchPublisherTest.java
similarity index 97%
rename from src/test/java/com/att/nsa/mr/client/impl/MRBatchPublisherTest.java
rename to src/test/java/org/onap/dmaap/mr/client/impl/MRBatchPublisherTest.java
index 19b58e9..f13e7fa 100644
--- a/src/test/java/com/att/nsa/mr/client/impl/MRBatchPublisherTest.java
+++ b/src/test/java/org/onap/dmaap/mr/client/impl/MRBatchPublisherTest.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.client.impl;
+package org.onap.dmaap.mr.client.impl;
 
 import java.io.IOException;
 import java.util.Arrays;
diff --git a/src/test/java/com/att/nsa/mr/client/impl/MRConstantsTest.java b/src/test/java/org/onap/dmaap/mr/client/impl/MRConstantsTest.java
similarity index 97%
rename from src/test/java/com/att/nsa/mr/client/impl/MRConstantsTest.java
rename to src/test/java/org/onap/dmaap/mr/client/impl/MRConstantsTest.java
index ed918b5..3a427e0 100644
--- a/src/test/java/com/att/nsa/mr/client/impl/MRConstantsTest.java
+++ b/src/test/java/org/onap/dmaap/mr/client/impl/MRConstantsTest.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.client.impl;
+package org.onap.dmaap.mr.client.impl;
 
 import java.io.IOException;
 import java.util.ArrayList;
@@ -31,7 +31,7 @@
 import org.apache.http.HttpHost;
 import org.junit.Test;
 
-import com.att.nsa.mr.client.impl.MRConstants;
+import org.onap.dmaap.mr.client.impl.MRConstants;
 
 public class MRConstantsTest extends TestCase
 {
diff --git a/src/test/java/com/att/nsa/mr/client/impl/MRConsumerImplTest.java b/src/test/java/org/onap/dmaap/mr/client/impl/MRConsumerImplTest.java
similarity index 96%
rename from src/test/java/com/att/nsa/mr/client/impl/MRConsumerImplTest.java
rename to src/test/java/org/onap/dmaap/mr/client/impl/MRConsumerImplTest.java
index bfac947..5d8dccd 100644
--- a/src/test/java/com/att/nsa/mr/client/impl/MRConsumerImplTest.java
+++ b/src/test/java/org/onap/dmaap/mr/client/impl/MRConsumerImplTest.java
@@ -19,7 +19,7 @@
  *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
  *  
  *******************************************************************************/
-package com.att.nsa.mr.client.impl;
+package org.onap.dmaap.mr.client.impl;
 
 import java.io.IOException;
 import java.util.LinkedList;
@@ -29,9 +29,9 @@
 
 import org.junit.Test;
 
-import com.att.nsa.mr.client.MRClientFactory;
-import com.att.nsa.mr.client.impl.MRConstants;
-import com.att.nsa.mr.client.impl.MRConsumerImpl;
+import org.onap.dmaap.mr.client.MRClientFactory;
+import org.onap.dmaap.mr.client.impl.MRConstants;
+import org.onap.dmaap.mr.client.impl.MRConsumerImpl;
 
 public class MRConsumerImplTest extends TestCase
 {
diff --git a/src/test/java/com/att/nsa/mr/client/impl/MRMetaClientTest.java b/src/test/java/org/onap/dmaap/mr/client/impl/MRMetaClientTest.java
similarity index 95%
rename from src/test/java/com/att/nsa/mr/client/impl/MRMetaClientTest.java
rename to src/test/java/org/onap/dmaap/mr/client/impl/MRMetaClientTest.java
index 4a3650f..6c2b219 100644
--- a/src/test/java/com/att/nsa/mr/client/impl/MRMetaClientTest.java
+++ b/src/test/java/org/onap/dmaap/mr/client/impl/MRMetaClientTest.java
@@ -1,129 +1,129 @@
-/*******************************************************************************
- *  ============LICENSE_START=======================================================
- *  org.onap.dmaap
- *  ================================================================================
- *  Copyright © 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=========================================================
- *
- *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
- *  
- *******************************************************************************/
-package com.att.nsa.mr.client.impl;
-
-import java.io.IOException;
-import java.net.MalformedURLException;
-import java.util.Collection;
-import java.util.LinkedList;
-import java.util.Set;
-
-import org.junit.Before;
-import org.junit.Rule;
-import org.junit.Test;
-
-import static com.github.tomakehurst.wiremock.client.WireMock.*;
-import static org.junit.Assert.assertTrue;
-
-import com.att.nsa.apiClient.http.HttpException;
-import com.att.nsa.apiClient.http.HttpObjectNotFoundException;
-import com.att.nsa.mr.client.MRClient.MRApiException;
-import com.att.nsa.mr.client.MRTopicManager.TopicInfo;
-import com.github.tomakehurst.wiremock.junit.WireMockRule;
-
-
-public class MRMetaClientTest {
-	
-	@Rule public WireMockRule wireMock = new WireMockRule();
-	
-	@Before
-	public void setUp(){
-		wireMock.stubFor(get(urlEqualTo("/topics"))
-                .willReturn(aResponse().withBody("{\"topics\":[\"topic1\",\"topic2\"]}").withHeader("Content-Type", "application/json")));
-		wireMock.stubFor(get(urlEqualTo("/topics/topic1"))
-                .willReturn(aResponse().withBody("{\"topics\":[\"topic1\",\"topic2\"]}").withHeader("Content-Type", "application/json")));
-		wireMock.stubFor(post(urlEqualTo("/topics/create"))
-				.willReturn(aResponse().withStatus(200)));
-	}
-	
-	@Test
-	public void getTopicsTest() 
-	{
-		final Collection<String> hosts = new LinkedList<String> ();
-		hosts.add ( "localhost:" + wireMock.port() );
-		
-		MRMetaClient c;
-		try {
-			c = new MRMetaClient(hosts);
-			Set<String> setString=c.getTopics();
-		} catch (IOException e) {
-			e.printStackTrace();
-		}
-		
-		
-	//	assertEquals ("http://localhost:8080/events/" + "topic/cg/cid", url );
-		
-	}
-	
-	@Test
-	public void getTopicMetadataTest() {
-		final Collection<String> hosts = new LinkedList<String> ();
-		hosts.add ( "localhost:" + wireMock.port() );
-		
-		final String topic ="topic1";
-		
-		MRMetaClient c;
-		try {
-			c = new MRMetaClient(hosts);
-			TopicInfo topicInfo=c.getTopicMetadata(topic);
-		} catch (IOException | HttpObjectNotFoundException e) {
-			e.printStackTrace();
-		}	
-		
-	}
-	
-	@Test
-	public void testcreateTopic(){
-		final Collection<String> hosts = new LinkedList<String> ();
-		hosts.add ( "localhost:" + wireMock.port() );
-		
-		MRMetaClient c;
-		try {
-			c = new MRMetaClient(hosts);
-			c.createTopic("topic1", "testTopic", 1, 1);
-		} catch (IOException | HttpException e) {
-			e.printStackTrace();
-		}
-	}
-	@Test
-	public void testupdateApiKey(){
-		final Collection<String> hosts = new LinkedList<String> ();
-		hosts.add ( "localhost:" + wireMock.port() );
-		
-		MRMetaClient c;
-		try {
-			c = new MRMetaClient(hosts);
-			c.updateCurrentApiKey("test@onap.com", "test email");
-		}catch (HttpException e) {
-			
-		} catch (IOException e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		}
-		catch (NullPointerException e) {
-			assertTrue(true);
-		}
-		
-	}
-
-	
-}
+/*******************************************************************************
+ *  ============LICENSE_START=======================================================
+ *  org.onap.dmaap
+ *  ================================================================================
+ *  Copyright © 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=========================================================
+ *
+ *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
+ *  
+ *******************************************************************************/
+package org.onap.dmaap.mr.client.impl;
+
+import java.io.IOException;
+import java.net.MalformedURLException;
+import java.util.Collection;
+import java.util.LinkedList;
+import java.util.Set;
+
+import org.junit.Before;
+import org.junit.Rule;
+import org.junit.Test;
+
+import static com.github.tomakehurst.wiremock.client.WireMock.*;
+import static org.junit.Assert.assertTrue;
+
+import com.att.nsa.apiClient.http.HttpException;
+import com.att.nsa.apiClient.http.HttpObjectNotFoundException;
+import org.onap.dmaap.mr.client.MRClient.MRApiException;
+import org.onap.dmaap.mr.client.MRTopicManager.TopicInfo;
+import com.github.tomakehurst.wiremock.junit.WireMockRule;
+
+
+public class MRMetaClientTest {
+	
+	@Rule public WireMockRule wireMock = new WireMockRule();
+	
+	@Before
+	public void setUp(){
+		wireMock.stubFor(get(urlEqualTo("/topics"))
+                .willReturn(aResponse().withBody("{\"topics\":[\"topic1\",\"topic2\"]}").withHeader("Content-Type", "application/json")));
+		wireMock.stubFor(get(urlEqualTo("/topics/topic1"))
+                .willReturn(aResponse().withBody("{\"topics\":[\"topic1\",\"topic2\"]}").withHeader("Content-Type", "application/json")));
+		wireMock.stubFor(post(urlEqualTo("/topics/create"))
+				.willReturn(aResponse().withStatus(200)));
+	}
+	
+	@Test
+	public void getTopicsTest() 
+	{
+		final Collection<String> hosts = new LinkedList<String> ();
+		hosts.add ( "localhost:" + wireMock.port() );
+		
+		MRMetaClient c;
+		try {
+			c = new MRMetaClient(hosts);
+			Set<String> setString=c.getTopics();
+		} catch (IOException e) {
+			e.printStackTrace();
+		}
+		
+		
+	//	assertEquals ("http://localhost:8080/events/" + "topic/cg/cid", url );
+		
+	}
+	
+	@Test
+	public void getTopicMetadataTest() {
+		final Collection<String> hosts = new LinkedList<String> ();
+		hosts.add ( "localhost:" + wireMock.port() );
+		
+		final String topic ="topic1";
+		
+		MRMetaClient c;
+		try {
+			c = new MRMetaClient(hosts);
+			TopicInfo topicInfo=c.getTopicMetadata(topic);
+		} catch (IOException | HttpObjectNotFoundException e) {
+			e.printStackTrace();
+		}	
+		
+	}
+	
+	@Test
+	public void testcreateTopic(){
+		final Collection<String> hosts = new LinkedList<String> ();
+		hosts.add ( "localhost:" + wireMock.port() );
+		
+		MRMetaClient c;
+		try {
+			c = new MRMetaClient(hosts);
+			c.createTopic("topic1", "testTopic", 1, 1);
+		} catch (IOException | HttpException e) {
+			e.printStackTrace();
+		}
+	}
+	@Test
+	public void testupdateApiKey(){
+		final Collection<String> hosts = new LinkedList<String> ();
+		hosts.add ( "localhost:" + wireMock.port() );
+		
+		MRMetaClient c;
+		try {
+			c = new MRMetaClient(hosts);
+			c.updateCurrentApiKey("test@onap.com", "test email");
+		}catch (HttpException e) {
+			
+		} catch (IOException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+		catch (NullPointerException e) {
+			assertTrue(true);
+		}
+		
+	}
+
+	
+}
diff --git a/src/test/java/com/att/nsa/mr/client/impl/MRSimplerBatchConsumerTest.java b/src/test/java/org/onap/dmaap/mr/client/impl/MRSimplerBatchConsumerTest.java
similarity index 91%
rename from src/test/java/com/att/nsa/mr/client/impl/MRSimplerBatchConsumerTest.java
rename to src/test/java/org/onap/dmaap/mr/client/impl/MRSimplerBatchConsumerTest.java
index 506d277..af02c2f 100644
--- a/src/test/java/com/att/nsa/mr/client/impl/MRSimplerBatchConsumerTest.java
+++ b/src/test/java/org/onap/dmaap/mr/client/impl/MRSimplerBatchConsumerTest.java
@@ -1,76 +1,76 @@
-/*******************************************************************************
- *  ============LICENSE_START=======================================================
- *  org.onap.dmaap
- *  ================================================================================
- *  Copyright © 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=========================================================
- *
- *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
- *  
- *******************************************************************************/
-
-package com.att.nsa.mr.client.impl;
-
-import java.io.File;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.util.List;
-import java.util.Properties;
-import java.util.concurrent.TimeUnit;
-
-import org.json.JSONObject;
-import org.junit.After;
-import org.junit.Assert;
-import org.junit.Before;
-import org.junit.Test;
-
-import com.att.nsa.mr.client.MRClientFactory;
-import com.att.nsa.mr.client.MRConsumer;
-import com.att.nsa.mr.client.MRPublisher.message;
-import com.att.nsa.mr.client.response.MRPublisherResponse;
-
-public class MRSimplerBatchConsumerTest {
-	
-	File outFile;
-	@Before
-	public void setUp() throws Exception {
-		Properties properties = new Properties();
-		properties.load(MRSimplerBatchConsumerTest.class.getClassLoader().getResourceAsStream("dme2/consumer.properties"));
-		
-		String routeFilePath="dme2/preferredRoute.txt";
-		
-		File file = new File(MRSimplerBatchConsumerTest.class.getClassLoader().getResource(routeFilePath).getFile());
-		properties.put("DME2preferredRouterFilePath", MRSimplerBatchConsumerTest.class.getClassLoader().getResource(routeFilePath).getFile());
-		
-		outFile = new File(file.getParent() + "/consumer_tmp.properties");
-		properties.store(new FileOutputStream(outFile), "");
-	}
-
-	@Test
-	public void testSend() throws IOException, InterruptedException {
-				
-		final MRConsumer cc = MRClientFactory.createConsumer(outFile.getPath());	
-		
-		try {
-			for(String msg : cc.fetch()){
-				System.out.println(msg);
-			}
-		} catch (Exception e) {
-			System.err.println ( e.getClass().getName () + ": " + e.getMessage () );
-		}		
-		
-	}
-	
-
-}
+/*******************************************************************************
+ *  ============LICENSE_START=======================================================
+ *  org.onap.dmaap
+ *  ================================================================================
+ *  Copyright © 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=========================================================
+ *
+ *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
+ *  
+ *******************************************************************************/
+
+package org.onap.dmaap.mr.client.impl;
+
+import java.io.File;
+import java.io.FileOutputStream;
+import java.io.IOException;
+import java.util.List;
+import java.util.Properties;
+import java.util.concurrent.TimeUnit;
+
+import org.json.JSONObject;
+import org.junit.After;
+import org.junit.Assert;
+import org.junit.Before;
+import org.junit.Test;
+
+import org.onap.dmaap.mr.client.MRClientFactory;
+import org.onap.dmaap.mr.client.MRConsumer;
+import org.onap.dmaap.mr.client.MRPublisher.message;
+import org.onap.dmaap.mr.client.response.MRPublisherResponse;
+
+public class MRSimplerBatchConsumerTest {
+	
+	File outFile;
+	@Before
+	public void setUp() throws Exception {
+		Properties properties = new Properties();
+		properties.load(MRSimplerBatchConsumerTest.class.getClassLoader().getResourceAsStream("dme2/consumer.properties"));
+		
+		String routeFilePath="dme2/preferredRoute.txt";
+		
+		File file = new File(MRSimplerBatchConsumerTest.class.getClassLoader().getResource(routeFilePath).getFile());
+		properties.put("DME2preferredRouterFilePath", MRSimplerBatchConsumerTest.class.getClassLoader().getResource(routeFilePath).getFile());
+		
+		outFile = new File(file.getParent() + "/consumer_tmp.properties");
+		properties.store(new FileOutputStream(outFile), "");
+	}
+
+	@Test
+	public void testSend() throws IOException, InterruptedException {
+				
+		final MRConsumer cc = MRClientFactory.createConsumer(outFile.getPath());	
+		
+		try {
+			for(String msg : cc.fetch()){
+				System.out.println(msg);
+			}
+		} catch (Exception e) {
+			System.err.println ( e.getClass().getName () + ": " + e.getMessage () );
+		}		
+		
+	}
+	
+
+}
diff --git a/src/test/java/com/att/nsa/mr/client/impl/MRSimplerBatchPublisherTest.java b/src/test/java/org/onap/dmaap/mr/client/impl/MRSimplerBatchPublisherTest.java
similarity index 94%
rename from src/test/java/com/att/nsa/mr/client/impl/MRSimplerBatchPublisherTest.java
rename to src/test/java/org/onap/dmaap/mr/client/impl/MRSimplerBatchPublisherTest.java
index 5b8d580..2f9b519 100644
--- a/src/test/java/com/att/nsa/mr/client/impl/MRSimplerBatchPublisherTest.java
+++ b/src/test/java/org/onap/dmaap/mr/client/impl/MRSimplerBatchPublisherTest.java
@@ -1,96 +1,96 @@
-/*******************************************************************************
- *  ============LICENSE_START=======================================================
- *  org.onap.dmaap
- *  ================================================================================
- *  Copyright © 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=========================================================
- *
- *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
- *  
- *******************************************************************************/
-
-package com.att.nsa.mr.client.impl;
-
-import java.io.File;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.util.List;
-import java.util.Properties;
-import java.util.concurrent.TimeUnit;
-
-import org.json.JSONObject;
-import org.junit.After;
-import org.junit.Assert;
-import org.junit.Before;
-import org.junit.Test;
-
-import com.att.nsa.mr.client.MRClientFactory;
-import com.att.nsa.mr.client.MRPublisher.message;
-import com.att.nsa.mr.client.response.MRPublisherResponse;
-
-public class MRSimplerBatchPublisherTest {
-	
-	File outFile;
-	@Before
-	public void setUp() throws Exception {
-		Properties properties = new Properties();
-		properties.load(MRSimplerBatchPublisherTest.class.getClassLoader().getResourceAsStream("dme2/producer.properties"));
-		
-		String routeFilePath="dme2/preferredRoute.txt";
-		
-		File file = new File(MRSimplerBatchPublisherTest.class.getClassLoader().getResource(routeFilePath).getFile());
-		properties.put("DME2preferredRouterFilePath", MRSimplerBatchPublisherTest.class.getClassLoader().getResource(routeFilePath).getFile());
-		
-		outFile = new File(file.getParent() + "/producer_tmp.properties");
-		properties.store(new FileOutputStream(outFile), "");
-	}
-
-	@Test
-	public void testSend() throws IOException, InterruptedException {
-				
-		final MRSimplerBatchPublisher pub = (MRSimplerBatchPublisher)MRClientFactory.createBatchingPublisher(outFile.getPath());	
-		
-		//publish some messages
-		final JSONObject msg1 = new JSONObject ();
-		pub.send ( "MyPartitionKey", msg1.toString () );
-
-		final List<message> stuck = pub.close ( 1, TimeUnit.SECONDS );
-		if ( stuck.size () > 0 ) {
-			System.out.println( stuck.size() + " messages unsent" );
-		}
-		else
-		{
-			System.out.println ( "Clean exit; all messages sent." );
-		}
-		
-		
-	}
-
-	@Test
-	public void testSendBatchWithResponse() throws IOException, InterruptedException {
-				
-		final MRSimplerBatchPublisher pub = (MRSimplerBatchPublisher)MRClientFactory.createBatchingPublisher(outFile.getPath(), true);	
-		
-		//publish some messages
-		final JSONObject msg1 = new JSONObject ();
-		pub.send ( "MyPartitionKey", msg1.toString () );
-		MRPublisherResponse pubResponse = new MRPublisherResponse();
-		pub.setPubResponse(pubResponse);
-		
-		MRPublisherResponse mrPublisherResponse = pub.sendBatchWithResponse();
-		Assert.assertEquals(1, mrPublisherResponse.getPendingMsgs());
-		
-	}
-
-}
+/*******************************************************************************
+ *  ============LICENSE_START=======================================================
+ *  org.onap.dmaap
+ *  ================================================================================
+ *  Copyright © 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=========================================================
+ *
+ *  ECOMP is a trademark and service mark of AT&T Intellectual Property.
+ *  
+ *******************************************************************************/
+
+package org.onap.dmaap.mr.client.impl;
+
+import java.io.File;
+import java.io.FileOutputStream;
+import java.io.IOException;
+import java.util.List;
+import java.util.Properties;
+import java.util.concurrent.TimeUnit;
+
+import org.json.JSONObject;
+import org.junit.After;
+import org.junit.Assert;
+import org.junit.Before;
+import org.junit.Test;
+
+import org.onap.dmaap.mr.client.MRClientFactory;
+import org.onap.dmaap.mr.client.MRPublisher.message;
+import org.onap.dmaap.mr.client.response.MRPublisherResponse;
+
+public class MRSimplerBatchPublisherTest {
+	
+	File outFile;
+	@Before
+	public void setUp() throws Exception {
+		Properties properties = new Properties();
+		properties.load(MRSimplerBatchPublisherTest.class.getClassLoader().getResourceAsStream("dme2/producer.properties"));
+		
+		String routeFilePath="dme2/preferredRoute.txt";
+		
+		File file = new File(MRSimplerBatchPublisherTest.class.getClassLoader().getResource(routeFilePath).getFile());
+		properties.put("DME2preferredRouterFilePath", MRSimplerBatchPublisherTest.class.getClassLoader().getResource(routeFilePath).getFile());
+		
+		outFile = new File(file.getParent() + "/producer_tmp.properties");
+		properties.store(new FileOutputStream(outFile), "");
+	}
+
+	@Test
+	public void testSend() throws IOException, InterruptedException {
+				
+		final MRSimplerBatchPublisher pub = (MRSimplerBatchPublisher)MRClientFactory.createBatchingPublisher(outFile.getPath());	
+		
+		//publish some messages
+		final JSONObject msg1 = new JSONObject ();
+		pub.send ( "MyPartitionKey", msg1.toString () );
+
+		final List<message> stuck = pub.close ( 1, TimeUnit.SECONDS );
+		if ( stuck.size () > 0 ) {
+			System.out.println( stuck.size() + " messages unsent" );
+		}
+		else
+		{
+			System.out.println ( "Clean exit; all messages sent." );
+		}
+		
+		
+	}
+
+	@Test
+	public void testSendBatchWithResponse() throws IOException, InterruptedException {
+				
+		final MRSimplerBatchPublisher pub = (MRSimplerBatchPublisher)MRClientFactory.createBatchingPublisher(outFile.getPath(), true);	
+		
+		//publish some messages
+		final JSONObject msg1 = new JSONObject ();
+		pub.send ( "MyPartitionKey", msg1.toString () );
+		MRPublisherResponse pubResponse = new MRPublisherResponse();
+		pub.setPubResponse(pubResponse);
+		
+		MRPublisherResponse mrPublisherResponse = pub.sendBatchWithResponse();
+		Assert.assertEquals(1, mrPublisherResponse.getPendingMsgs());
+		
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/client/response/JUnitTestSuite.java b/src/test/java/org/onap/dmaap/mr/client/response/JUnitTestSuite.java
similarity index 97%
rename from src/test/java/com/att/nsa/mr/client/response/JUnitTestSuite.java
rename to src/test/java/org/onap/dmaap/mr/client/response/JUnitTestSuite.java
index 90b10a9..1cfaef4 100644
--- a/src/test/java/com/att/nsa/mr/client/response/JUnitTestSuite.java
+++ b/src/test/java/org/onap/dmaap/mr/client/response/JUnitTestSuite.java
@@ -1,43 +1,43 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.client.response;
-
-import junit.framework.TestSuite;
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-import org.junit.runners.Suite.SuiteClasses;
-import org.apache.log4j.Logger;
-
-@RunWith(Suite.class)
-@SuiteClasses({ MRConsumerResponseTest.class, MRPublisherResponseTest.class,})
-
-public class JUnitTestSuite {
-	private static final Logger LOGGER = Logger.getLogger(JUnitTestSuite.class);
-
-	public static void main(String[] args) {
-		LOGGER.info("Running the test suite");
-		
-		TestSuite tstSuite = new TestSuite();
-		LOGGER.info("Total Test Counts " + tstSuite.countTestCases());
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.client.response;
+
+import junit.framework.TestSuite;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Suite;
+import org.junit.runners.Suite.SuiteClasses;
+import org.apache.log4j.Logger;
+
+@RunWith(Suite.class)
+@SuiteClasses({ MRConsumerResponseTest.class, MRPublisherResponseTest.class,})
+
+public class JUnitTestSuite {
+	private static final Logger LOGGER = Logger.getLogger(JUnitTestSuite.class);
+
+	public static void main(String[] args) {
+		LOGGER.info("Running the test suite");
+		
+		TestSuite tstSuite = new TestSuite();
+		LOGGER.info("Total Test Counts " + tstSuite.countTestCases());
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/client/response/MRConsumerResponseTest.java b/src/test/java/org/onap/dmaap/mr/client/response/MRConsumerResponseTest.java
similarity index 95%
rename from src/test/java/com/att/nsa/mr/client/response/MRConsumerResponseTest.java
rename to src/test/java/org/onap/dmaap/mr/client/response/MRConsumerResponseTest.java
index 036a216..3f727a4 100644
--- a/src/test/java/com/att/nsa/mr/client/response/MRConsumerResponseTest.java
+++ b/src/test/java/org/onap/dmaap/mr/client/response/MRConsumerResponseTest.java
@@ -1,94 +1,94 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.client.response;
-
-import static org.junit.Assert.assertTrue;
-
-import java.util.concurrent.TimeUnit;
-
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-
-import com.att.nsa.mr.client.HostSelector;
-
-public class MRConsumerResponseTest {
-	private MRConsumerResponse test = null;
-
-	@Before
-	public void setUp() throws Exception {
-		test = new MRConsumerResponse();
-
-	}
-
-	@After
-	public void tearDown() throws Exception {
-
-	}
-
-	@Test
-	public void testGetResponseCode() {
-
-		test.getResponseCode();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testSetResponseCode() {
-
-		test.setResponseCode("200");
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testGetResponseMessage() {
-
-		test.getResponseMessage();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testSetResponseMessage() {
-
-		test.setResponseMessage("responseMessage");
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testGetActualMessages() {
-
-		test.getActualMessages();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testSetActualMessages() {
-
-		test.setActualMessages(null);
-		assertTrue(true);
-
-	}
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.client.response;
+
+import static org.junit.Assert.assertTrue;
+
+import java.util.concurrent.TimeUnit;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+
+import org.onap.dmaap.mr.client.HostSelector;
+
+public class MRConsumerResponseTest {
+	private MRConsumerResponse test = null;
+
+	@Before
+	public void setUp() throws Exception {
+		test = new MRConsumerResponse();
+
+	}
+
+	@After
+	public void tearDown() throws Exception {
+
+	}
+
+	@Test
+	public void testGetResponseCode() {
+
+		test.getResponseCode();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testSetResponseCode() {
+
+		test.setResponseCode("200");
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testGetResponseMessage() {
+
+		test.getResponseMessage();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testSetResponseMessage() {
+
+		test.setResponseMessage("responseMessage");
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testGetActualMessages() {
+
+		test.getActualMessages();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testSetActualMessages() {
+
+		test.setActualMessages(null);
+		assertTrue(true);
+
+	}
+}
diff --git a/src/test/java/com/att/nsa/mr/client/response/MRPublisherResponseTest.java b/src/test/java/org/onap/dmaap/mr/client/response/MRPublisherResponseTest.java
similarity index 95%
rename from src/test/java/com/att/nsa/mr/client/response/MRPublisherResponseTest.java
rename to src/test/java/org/onap/dmaap/mr/client/response/MRPublisherResponseTest.java
index 60e64ad..f4957db 100644
--- a/src/test/java/com/att/nsa/mr/client/response/MRPublisherResponseTest.java
+++ b/src/test/java/org/onap/dmaap/mr/client/response/MRPublisherResponseTest.java
@@ -1,104 +1,104 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.client.response;
-
-import static org.junit.Assert.assertTrue;
-
-import java.util.concurrent.TimeUnit;
-
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-
-import com.att.nsa.mr.client.HostSelector;
-
-public class MRPublisherResponseTest {
-	private MRPublisherResponse response = null;
-
-	@Before
-	public void setUp() throws Exception {
-		response = new MRPublisherResponse();
-
-	}
-
-	@After
-	public void tearDown() throws Exception {
-
-	}
-
-	@Test
-	public void testGetResponseCode() {
-
-		response.getResponseCode();
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testSetResponseCode() {
-
-		response.setResponseCode("200");
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testGetResponseMessage() {
-
-		response.getResponseMessage();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testSetResponseMessage() {
-
-		response.setResponseMessage("responseMessage");
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testGetPendingMsgs() {
-
-		response.getPendingMsgs();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testSetPendingMsgs() {
-
-		response.setPendingMsgs(5);
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testToString() {
-
-		response.toString();
-		assertTrue(true);
-
-	}
-
-	
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.client.response;
+
+import static org.junit.Assert.assertTrue;
+
+import java.util.concurrent.TimeUnit;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+
+import org.onap.dmaap.mr.client.HostSelector;
+
+public class MRPublisherResponseTest {
+	private MRPublisherResponse response = null;
+
+	@Before
+	public void setUp() throws Exception {
+		response = new MRPublisherResponse();
+
+	}
+
+	@After
+	public void tearDown() throws Exception {
+
+	}
+
+	@Test
+	public void testGetResponseCode() {
+
+		response.getResponseCode();
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testSetResponseCode() {
+
+		response.setResponseCode("200");
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testGetResponseMessage() {
+
+		response.getResponseMessage();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testSetResponseMessage() {
+
+		response.setResponseMessage("responseMessage");
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testGetPendingMsgs() {
+
+		response.getPendingMsgs();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testSetPendingMsgs() {
+
+		response.setPendingMsgs(5);
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testToString() {
+
+		response.toString();
+		assertTrue(true);
+
+	}
+
+	
+}
diff --git a/src/test/java/com/att/nsa/mr/dme/client/TestRunner.java b/src/test/java/org/onap/dmaap/mr/client/response/TestRunner.java
similarity index 96%
copy from src/test/java/com/att/nsa/mr/dme/client/TestRunner.java
copy to src/test/java/org/onap/dmaap/mr/client/response/TestRunner.java
index 08be6da..9bf5880 100644
--- a/src/test/java/com/att/nsa/mr/dme/client/TestRunner.java
+++ b/src/test/java/org/onap/dmaap/mr/client/response/TestRunner.java
@@ -1,41 +1,41 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.dme.client;
-
-import org.junit.runner.JUnitCore;
-import org.junit.runner.Result;
-import org.junit.runner.notification.Failure;
-import org.apache.log4j.Logger;
-
-public class TestRunner {
-	private static final Logger LOGGER = Logger.getLogger(TestRunner.class);
-
-	public static void main(String[] args) {
-		// TODO Auto-generated method stub
-		Result result = JUnitCore.runClasses(JUnitTestSuite.class);
-		for (Failure failure : result.getFailures()) {
-			LOGGER.info(failure.toString());
-			
-		}
-		LOGGER.info(result.wasSuccessful());
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.client.response;
+
+import org.junit.runner.JUnitCore;
+import org.junit.runner.Result;
+import org.junit.runner.notification.Failure;
+import org.apache.log4j.Logger;
+
+public class TestRunner {
+	private static final Logger LOGGER = Logger.getLogger(TestRunner.class);
+
+	public static void main(String[] args) {
+		// TODO Auto-generated method stub
+		Result result = JUnitCore.runClasses(JUnitTestSuite.class);
+		for (Failure failure : result.getFailures()) {
+			LOGGER.info(failure.toString());
+			
+		}
+		LOGGER.info(result.wasSuccessful());
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/dme/client/DefaultLoggingFailoverFaultHandlerTest.java b/src/test/java/org/onap/dmaap/mr/dme/client/DefaultLoggingFailoverFaultHandlerTest.java
similarity index 89%
rename from src/test/java/com/att/nsa/mr/dme/client/DefaultLoggingFailoverFaultHandlerTest.java
rename to src/test/java/org/onap/dmaap/mr/dme/client/DefaultLoggingFailoverFaultHandlerTest.java
index 5f67f6d..b1c7e15 100644
--- a/src/test/java/com/att/nsa/mr/dme/client/DefaultLoggingFailoverFaultHandlerTest.java
+++ b/src/test/java/org/onap/dmaap/mr/dme/client/DefaultLoggingFailoverFaultHandlerTest.java
@@ -1,69 +1,69 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.dme.client;
-
-import static org.junit.Assert.assertTrue;
-
-import java.lang.reflect.Constructor;
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
-import java.util.ArrayList;
-import java.util.concurrent.TimeUnit;
-
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-
-import com.att.nsa.mr.client.HostSelector;
-import com.att.nsa.mr.client.MRPublisher.message;
-import com.att.nsa.mr.test.support.MRBatchingPublisherMock.Listener;
-
-public class DefaultLoggingFailoverFaultHandlerTest {
-	private DefaultLoggingFailoverFaultHandler handler = null;
-
-	@Before
-	public void setUp() throws Exception {
-		handler = new DefaultLoggingFailoverFaultHandler();
-
-	}
-
-	@After
-	public void tearDown() throws Exception {
-
-	}
-
-	@Test
-	public void testHandleEndpointFailover() {
-
-	/*	handler.handleEndpointFailover(null);
-		assertTrue(true);*/
-
-	}
-	
-	@Test
-	public void testHandleRouteOfferFailover() {
-
-	/*	handler.handleRouteOfferFailover(null);
-		assertTrue(true);
-*/
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.dme.client;
+
+import static org.junit.Assert.assertTrue;
+
+import java.lang.reflect.Constructor;
+import java.lang.reflect.InvocationTargetException;
+import java.lang.reflect.Method;
+import java.util.ArrayList;
+import java.util.concurrent.TimeUnit;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+
+import org.onap.dmaap.mr.client.HostSelector;
+import org.onap.dmaap.mr.client.MRPublisher.message;
+import org.onap.dmaap.mr.test.support.MRBatchingPublisherMock.Listener;
+
+public class DefaultLoggingFailoverFaultHandlerTest {
+	private DefaultLoggingFailoverFaultHandler handler = null;
+
+	@Before
+	public void setUp() throws Exception {
+		handler = new DefaultLoggingFailoverFaultHandler();
+
+	}
+
+	@After
+	public void tearDown() throws Exception {
+
+	}
+
+	@Test
+	public void testHandleEndpointFailover() {
+
+	/*	handler.handleEndpointFailover(null);
+		assertTrue(true);*/
+
+	}
+	
+	@Test
+	public void testHandleRouteOfferFailover() {
+
+	/*	handler.handleRouteOfferFailover(null);
+		assertTrue(true);
+*/
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/dme/client/HeaderReplyHandlerTest.java b/src/test/java/org/onap/dmaap/mr/dme/client/HeaderReplyHandlerTest.java
similarity index 89%
rename from src/test/java/com/att/nsa/mr/dme/client/HeaderReplyHandlerTest.java
rename to src/test/java/org/onap/dmaap/mr/dme/client/HeaderReplyHandlerTest.java
index bdcff83..df236c9 100644
--- a/src/test/java/com/att/nsa/mr/dme/client/HeaderReplyHandlerTest.java
+++ b/src/test/java/org/onap/dmaap/mr/dme/client/HeaderReplyHandlerTest.java
@@ -1,79 +1,79 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.dme.client;
-
-import static org.junit.Assert.assertTrue;
-
-import java.lang.reflect.Constructor;
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
-import java.util.ArrayList;
-import java.util.concurrent.TimeUnit;
-
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-
-import com.att.nsa.mr.client.HostSelector;
-import com.att.nsa.mr.client.MRPublisher.message;
-import com.att.nsa.mr.test.support.MRBatchingPublisherMock.Listener;
-
-public class HeaderReplyHandlerTest {
-	private HeaderReplyHandler handler = null;
-
-	@Before
-	public void setUp() throws Exception {
-		handler = new HeaderReplyHandler();
-
-	}
-
-	@After
-	public void tearDown() throws Exception {
-
-	}
-
-	@Test
-	public void testHandleFault() {
-
-		handler.handleFault(null);
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testHandleEndpointFault() {
-
-		handler.handleEndpointFault(null);
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testHandleReply() {
-
-		handler.handleReply(null);
-		assertTrue(true);
-
-	}
-	
-	
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.dme.client;
+
+import static org.junit.Assert.assertTrue;
+
+import java.lang.reflect.Constructor;
+import java.lang.reflect.InvocationTargetException;
+import java.lang.reflect.Method;
+import java.util.ArrayList;
+import java.util.concurrent.TimeUnit;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+
+import org.onap.dmaap.mr.client.HostSelector;
+import org.onap.dmaap.mr.client.MRPublisher.message;
+import org.onap.dmaap.mr.test.support.MRBatchingPublisherMock.Listener;
+
+public class HeaderReplyHandlerTest {
+	private HeaderReplyHandler handler = null;
+
+	@Before
+	public void setUp() throws Exception {
+		handler = new HeaderReplyHandler();
+
+	}
+
+	@After
+	public void tearDown() throws Exception {
+
+	}
+
+	@Test
+	public void testHandleFault() {
+
+		handler.handleFault(null);
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testHandleEndpointFault() {
+
+		handler.handleEndpointFault(null);
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testHandleReply() {
+
+		handler.handleReply(null);
+		assertTrue(true);
+
+	}
+	
+	
+
+}
diff --git a/src/test/java/com/att/nsa/mr/dme/client/JUnitTestSuite.java b/src/test/java/org/onap/dmaap/mr/dme/client/JUnitTestSuite.java
similarity index 97%
rename from src/test/java/com/att/nsa/mr/dme/client/JUnitTestSuite.java
rename to src/test/java/org/onap/dmaap/mr/dme/client/JUnitTestSuite.java
index 3ce48a4..0d4c69a 100644
--- a/src/test/java/com/att/nsa/mr/dme/client/JUnitTestSuite.java
+++ b/src/test/java/org/onap/dmaap/mr/dme/client/JUnitTestSuite.java
@@ -1,44 +1,44 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.dme.client;
-
-import junit.framework.TestSuite;
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-import org.junit.runners.Suite.SuiteClasses;
-import org.apache.log4j.Logger;
-
-@RunWith(Suite.class)
-@SuiteClasses({ DefaultLoggingFailoverFaultHandlerTest.class, HeaderReplyHandlerTest.class,PreferredRouteReplyHandlerTest.class,
-	PreferredRouteRequestHandlerTest.class,SimpleExamplePublisherTest.class })
-
-public class JUnitTestSuite {
-	private static final Logger LOGGER = Logger.getLogger(JUnitTestSuite.class);
-
-	public static void main(String[] args) {
-		LOGGER.info("Running the test suite");
-		
-		TestSuite tstSuite = new TestSuite();
-		LOGGER.info("Total Test Counts " + tstSuite.countTestCases());
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.dme.client;
+
+import junit.framework.TestSuite;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Suite;
+import org.junit.runners.Suite.SuiteClasses;
+import org.apache.log4j.Logger;
+
+@RunWith(Suite.class)
+@SuiteClasses({ DefaultLoggingFailoverFaultHandlerTest.class, HeaderReplyHandlerTest.class,PreferredRouteReplyHandlerTest.class,
+	PreferredRouteRequestHandlerTest.class,SimpleExamplePublisherTest.class })
+
+public class JUnitTestSuite {
+	private static final Logger LOGGER = Logger.getLogger(JUnitTestSuite.class);
+
+	public static void main(String[] args) {
+		LOGGER.info("Running the test suite");
+		
+		TestSuite tstSuite = new TestSuite();
+		LOGGER.info("Total Test Counts " + tstSuite.countTestCases());
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/dme/client/PreferredRouteReplyHandlerTest.java b/src/test/java/org/onap/dmaap/mr/dme/client/PreferredRouteReplyHandlerTest.java
similarity index 90%
rename from src/test/java/com/att/nsa/mr/dme/client/PreferredRouteReplyHandlerTest.java
rename to src/test/java/org/onap/dmaap/mr/dme/client/PreferredRouteReplyHandlerTest.java
index 28f138d..5aa3018 100644
--- a/src/test/java/com/att/nsa/mr/dme/client/PreferredRouteReplyHandlerTest.java
+++ b/src/test/java/org/onap/dmaap/mr/dme/client/PreferredRouteReplyHandlerTest.java
@@ -1,88 +1,88 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.dme.client;
-
-import static org.junit.Assert.assertTrue;
-
-import java.lang.reflect.Constructor;
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
-import java.util.ArrayList;
-import java.util.concurrent.TimeUnit;
-
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-
-import com.att.nsa.mr.client.HostSelector;
-import com.att.nsa.mr.client.MRPublisher.message;
-import com.att.nsa.mr.test.support.MRBatchingPublisherMock.Listener;
-
-public class PreferredRouteReplyHandlerTest {
-	private PreferredRouteReplyHandler handler = null;
-
-	@Before
-	public void setUp() throws Exception {
-		handler = new PreferredRouteReplyHandler();
-
-	}
-
-	@After
-	public void tearDown() throws Exception {
-
-	}
-
-	@Test
-	public void testHandleReply() {
-
-//		handler.handleReply(null);
-//		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testHandleFault() {
-/*
-		handler.handleFault(null);
-		assertTrue(true);
-*/
-	}
-	
-	@Test
-	public void testHandleEndpointFault() {
-
-/*		handler.handleEndpointFault(null);
-		assertTrue(true);*/
-
-	}
-	
-	@Test
-	public void testRouteWriter() {
-/*
-		handler.routeWriter("routeKey", "routeValue");
-		assertTrue(true);
-*/
-	}
-	
-	
-	
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.dme.client;
+
+import static org.junit.Assert.assertTrue;
+
+import java.lang.reflect.Constructor;
+import java.lang.reflect.InvocationTargetException;
+import java.lang.reflect.Method;
+import java.util.ArrayList;
+import java.util.concurrent.TimeUnit;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+
+import org.onap.dmaap.mr.client.HostSelector;
+import org.onap.dmaap.mr.client.MRPublisher.message;
+import org.onap.dmaap.mr.test.support.MRBatchingPublisherMock.Listener;
+
+public class PreferredRouteReplyHandlerTest {
+	private PreferredRouteReplyHandler handler = null;
+
+	@Before
+	public void setUp() throws Exception {
+		handler = new PreferredRouteReplyHandler();
+
+	}
+
+	@After
+	public void tearDown() throws Exception {
+
+	}
+
+	@Test
+	public void testHandleReply() {
+
+//		handler.handleReply(null);
+//		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testHandleFault() {
+/*
+		handler.handleFault(null);
+		assertTrue(true);
+*/
+	}
+	
+	@Test
+	public void testHandleEndpointFault() {
+
+/*		handler.handleEndpointFault(null);
+		assertTrue(true);*/
+
+	}
+	
+	@Test
+	public void testRouteWriter() {
+/*
+		handler.routeWriter("routeKey", "routeValue");
+		assertTrue(true);
+*/
+	}
+	
+	
+	
+
+}
diff --git a/src/test/java/com/att/nsa/mr/dme/client/PreferredRouteRequestHandlerTest.java b/src/test/java/org/onap/dmaap/mr/dme/client/PreferredRouteRequestHandlerTest.java
similarity index 89%
rename from src/test/java/com/att/nsa/mr/dme/client/PreferredRouteRequestHandlerTest.java
rename to src/test/java/org/onap/dmaap/mr/dme/client/PreferredRouteRequestHandlerTest.java
index 86f220c..cf5b607 100644
--- a/src/test/java/com/att/nsa/mr/dme/client/PreferredRouteRequestHandlerTest.java
+++ b/src/test/java/org/onap/dmaap/mr/dme/client/PreferredRouteRequestHandlerTest.java
@@ -1,74 +1,74 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.dme.client;
-
-import static org.junit.Assert.assertTrue;
-
-import java.lang.reflect.Constructor;
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
-import java.util.ArrayList;
-import java.util.concurrent.TimeUnit;
-
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-
-import com.att.nsa.mr.client.HostSelector;
-import com.att.nsa.mr.client.MRPublisher.message;
-import com.att.nsa.mr.test.support.MRBatchingPublisherMock.Listener;
-
-public class PreferredRouteRequestHandlerTest {
-	private PreferredRouteRequestHandler handler = null;
-
-	@Before
-	public void setUp() throws Exception {
-		handler = new PreferredRouteRequestHandler();
-
-	}
-
-	@After
-	public void tearDown() throws Exception {
-
-	}
-
-	@Test
-	public void testHandleRequest() {
-
-	/*	handler.handleRequest(null);
-		assertTrue(true);*/
-
-	}
-
-	@Test
-	public void testReadRoute() {
-
-//		try {
-//			handler.readRoute("routeKey");
-//		} catch (NullPointerException e) {
-//			assertTrue(true);
-//		}
-//
-//		assertTrue(true);
-
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.dme.client;
+
+import static org.junit.Assert.assertTrue;
+
+import java.lang.reflect.Constructor;
+import java.lang.reflect.InvocationTargetException;
+import java.lang.reflect.Method;
+import java.util.ArrayList;
+import java.util.concurrent.TimeUnit;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+
+import org.onap.dmaap.mr.client.HostSelector;
+import org.onap.dmaap.mr.client.MRPublisher.message;
+import org.onap.dmaap.mr.test.support.MRBatchingPublisherMock.Listener;
+
+public class PreferredRouteRequestHandlerTest {
+	private PreferredRouteRequestHandler handler = null;
+
+	@Before
+	public void setUp() throws Exception {
+		handler = new PreferredRouteRequestHandler();
+
+	}
+
+	@After
+	public void tearDown() throws Exception {
+
+	}
+
+	@Test
+	public void testHandleRequest() {
+
+	/*	handler.handleRequest(null);
+		assertTrue(true);*/
+
+	}
+
+	@Test
+	public void testReadRoute() {
+
+//		try {
+//			handler.readRoute("routeKey");
+//		} catch (NullPointerException e) {
+//			assertTrue(true);
+//		}
+//
+//		assertTrue(true);
+
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/dme/client/SimpleExamplePublisherTest.java b/src/test/java/org/onap/dmaap/mr/dme/client/SimpleExamplePublisherTest.java
similarity index 89%
rename from src/test/java/com/att/nsa/mr/dme/client/SimpleExamplePublisherTest.java
rename to src/test/java/org/onap/dmaap/mr/dme/client/SimpleExamplePublisherTest.java
index 67051b1..1240d8b 100644
--- a/src/test/java/com/att/nsa/mr/dme/client/SimpleExamplePublisherTest.java
+++ b/src/test/java/org/onap/dmaap/mr/dme/client/SimpleExamplePublisherTest.java
@@ -1,68 +1,68 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.dme.client;
-
-import static org.junit.Assert.assertTrue;
-
-import java.lang.reflect.Constructor;
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
-import java.util.ArrayList;
-import java.util.concurrent.TimeUnit;
-
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-
-import com.att.nsa.mr.client.HostSelector;
-import com.att.nsa.mr.client.MRPublisher.message;
-import com.att.nsa.mr.test.support.MRBatchingPublisherMock.Listener;
-
-public class SimpleExamplePublisherTest {
-	private SimpleExamplePublisher pub = null;
-
-	@Before
-	public void setUp() throws Exception {
-		pub = new SimpleExamplePublisher();
-
-	}
-
-	@After
-	public void tearDown() throws Exception {
-
-	}
-
-	@Test
-	public void testPublishMessage() {
-
-		try {
-			pub.publishMessage("/producer");
-		} catch (Exception e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		}
-		assertTrue(true);
-
-	}
-
-	
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.dme.client;
+
+import static org.junit.Assert.assertTrue;
+
+import java.lang.reflect.Constructor;
+import java.lang.reflect.InvocationTargetException;
+import java.lang.reflect.Method;
+import java.util.ArrayList;
+import java.util.concurrent.TimeUnit;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+
+import org.onap.dmaap.mr.client.HostSelector;
+import org.onap.dmaap.mr.client.MRPublisher.message;
+import org.onap.dmaap.mr.test.support.MRBatchingPublisherMock.Listener;
+
+public class SimpleExamplePublisherTest {
+	private SimpleExamplePublisher pub = null;
+
+	@Before
+	public void setUp() throws Exception {
+		pub = new SimpleExamplePublisher();
+
+	}
+
+	@After
+	public void tearDown() throws Exception {
+
+	}
+
+	@Test
+	public void testPublishMessage() {
+
+		try {
+			pub.publishMessage("/producer");
+		} catch (Exception e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+		assertTrue(true);
+
+	}
+
+	
+
+}
diff --git a/src/test/java/com/att/nsa/mr/dme/client/TestRunner.java b/src/test/java/org/onap/dmaap/mr/dme/client/TestRunner.java
similarity index 97%
rename from src/test/java/com/att/nsa/mr/dme/client/TestRunner.java
rename to src/test/java/org/onap/dmaap/mr/dme/client/TestRunner.java
index 08be6da..74928c9 100644
--- a/src/test/java/com/att/nsa/mr/dme/client/TestRunner.java
+++ b/src/test/java/org/onap/dmaap/mr/dme/client/TestRunner.java
@@ -1,41 +1,41 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.dme.client;
-
-import org.junit.runner.JUnitCore;
-import org.junit.runner.Result;
-import org.junit.runner.notification.Failure;
-import org.apache.log4j.Logger;
-
-public class TestRunner {
-	private static final Logger LOGGER = Logger.getLogger(TestRunner.class);
-
-	public static void main(String[] args) {
-		// TODO Auto-generated method stub
-		Result result = JUnitCore.runClasses(JUnitTestSuite.class);
-		for (Failure failure : result.getFailures()) {
-			LOGGER.info(failure.toString());
-			
-		}
-		LOGGER.info(result.wasSuccessful());
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.dme.client;
+
+import org.junit.runner.JUnitCore;
+import org.junit.runner.Result;
+import org.junit.runner.notification.Failure;
+import org.apache.log4j.Logger;
+
+public class TestRunner {
+	private static final Logger LOGGER = Logger.getLogger(TestRunner.class);
+
+	public static void main(String[] args) {
+		// TODO Auto-generated method stub
+		Result result = JUnitCore.runClasses(JUnitTestSuite.class);
+		for (Failure failure : result.getFailures()) {
+			LOGGER.info(failure.toString());
+			
+		}
+		LOGGER.info(result.wasSuccessful());
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/logging/JUnitTestSuite.java b/src/test/java/org/onap/dmaap/mr/logging/JUnitTestSuite.java
similarity index 97%
rename from src/test/java/com/att/nsa/mr/logging/JUnitTestSuite.java
rename to src/test/java/org/onap/dmaap/mr/logging/JUnitTestSuite.java
index 43fe365..8828d1c 100644
--- a/src/test/java/com/att/nsa/mr/logging/JUnitTestSuite.java
+++ b/src/test/java/org/onap/dmaap/mr/logging/JUnitTestSuite.java
@@ -1,43 +1,43 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.logging;
-
-import junit.framework.TestSuite;
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-import org.junit.runners.Suite.SuiteClasses;
-import org.apache.log4j.Logger;
-
-@RunWith(Suite.class)
-@SuiteClasses({ MRAppenderTest.class, })
-
-public class JUnitTestSuite {
-	private static final Logger LOGGER = Logger.getLogger(JUnitTestSuite.class);
-
-	public static void main(String[] args) {
-		LOGGER.info("Running the test suite");
-		
-		TestSuite tstSuite = new TestSuite();
-		LOGGER.info("Total Test Counts " + tstSuite.countTestCases());
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.logging;
+
+import junit.framework.TestSuite;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Suite;
+import org.junit.runners.Suite.SuiteClasses;
+import org.apache.log4j.Logger;
+
+@RunWith(Suite.class)
+@SuiteClasses({ MRAppenderTest.class, })
+
+public class JUnitTestSuite {
+	private static final Logger LOGGER = Logger.getLogger(JUnitTestSuite.class);
+
+	public static void main(String[] args) {
+		LOGGER.info("Running the test suite");
+		
+		TestSuite tstSuite = new TestSuite();
+		LOGGER.info("Total Test Counts " + tstSuite.countTestCases());
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/logging/MRAppenderTest.java b/src/test/java/org/onap/dmaap/mr/logging/MRAppenderTest.java
similarity index 97%
rename from src/test/java/com/att/nsa/mr/logging/MRAppenderTest.java
rename to src/test/java/org/onap/dmaap/mr/logging/MRAppenderTest.java
index 0a59d97..8332606 100644
--- a/src/test/java/com/att/nsa/mr/logging/MRAppenderTest.java
+++ b/src/test/java/org/onap/dmaap/mr/logging/MRAppenderTest.java
@@ -1,184 +1,184 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.logging;
-
-import static org.junit.Assert.assertTrue;
-
-import java.util.concurrent.TimeUnit;
-
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-
-import com.att.nsa.mr.client.HostSelector;
-
-public class MRAppenderTest {
-	private MRAppender appender = null;
-
-	@Before
-	public void setUp() throws Exception {
-		appender = new MRAppender();
-
-	}
-
-	@After
-	public void tearDown() throws Exception {
-
-	}
-
-	@Test
-	public void testClose() {
-		try {
-			appender.close();
-		} catch (NullPointerException e) {
-			assertTrue(true);
-		}
-
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testRequiresLayout() {
-
-		appender.requiresLayout();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testAppend() {
-
-		try {
-			appender.append(null);
-		} catch (NullPointerException e) {
-			assertTrue(true);
-		}
-
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testActivateOptions() {
-
-		appender.activateOptions();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testGetTopic() {
-
-		appender.getTopic();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testSetTopic() {
-
-		appender.setTopic("testTopic");
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testGetPartition() {
-
-		appender.getPartition();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testSetPartition() {
-
-		appender.setPartition("partition");
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testGetHosts() {
-
-		appender.getHosts();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testSetHosts() {
-
-		appender.setHosts("hosts");
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testGetMaxBatchSize() {
-
-		appender.getMaxBatchSize();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testSetMaxBatchSize() {
-
-		appender.setMaxBatchSize(20);
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testGetMaxAgeMs() {
-
-		appender.getMaxAgeMs();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testSetMaxAgeMs() {
-
-		appender.setMaxAgeMs(15);
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testIsCompress() {
-
-		appender.isCompress();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testSetCompress() {
-
-		appender.setCompress(true);
-		assertTrue(true);
-
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.logging;
+
+import static org.junit.Assert.assertTrue;
+
+import java.util.concurrent.TimeUnit;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+
+import org.onap.dmaap.mr.client.HostSelector;
+
+public class MRAppenderTest {
+	private MRAppender appender = null;
+
+	@Before
+	public void setUp() throws Exception {
+		appender = new MRAppender();
+
+	}
+
+	@After
+	public void tearDown() throws Exception {
+
+	}
+
+	@Test
+	public void testClose() {
+		try {
+			appender.close();
+		} catch (NullPointerException e) {
+			assertTrue(true);
+		}
+
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testRequiresLayout() {
+
+		appender.requiresLayout();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testAppend() {
+
+		try {
+			appender.append(null);
+		} catch (NullPointerException e) {
+			assertTrue(true);
+		}
+
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testActivateOptions() {
+
+		appender.activateOptions();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testGetTopic() {
+
+		appender.getTopic();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testSetTopic() {
+
+		appender.setTopic("testTopic");
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testGetPartition() {
+
+		appender.getPartition();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testSetPartition() {
+
+		appender.setPartition("partition");
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testGetHosts() {
+
+		appender.getHosts();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testSetHosts() {
+
+		appender.setHosts("hosts");
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testGetMaxBatchSize() {
+
+		appender.getMaxBatchSize();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testSetMaxBatchSize() {
+
+		appender.setMaxBatchSize(20);
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testGetMaxAgeMs() {
+
+		appender.getMaxAgeMs();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testSetMaxAgeMs() {
+
+		appender.setMaxAgeMs(15);
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testIsCompress() {
+
+		appender.isCompress();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testSetCompress() {
+
+		appender.setCompress(true);
+		assertTrue(true);
+
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/dme/client/TestRunner.java b/src/test/java/org/onap/dmaap/mr/logging/TestRunner.java
similarity index 97%
copy from src/test/java/com/att/nsa/mr/dme/client/TestRunner.java
copy to src/test/java/org/onap/dmaap/mr/logging/TestRunner.java
index 08be6da..8e77136 100644
--- a/src/test/java/com/att/nsa/mr/dme/client/TestRunner.java
+++ b/src/test/java/org/onap/dmaap/mr/logging/TestRunner.java
@@ -1,41 +1,41 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.dme.client;
-
-import org.junit.runner.JUnitCore;
-import org.junit.runner.Result;
-import org.junit.runner.notification.Failure;
-import org.apache.log4j.Logger;
-
-public class TestRunner {
-	private static final Logger LOGGER = Logger.getLogger(TestRunner.class);
-
-	public static void main(String[] args) {
-		// TODO Auto-generated method stub
-		Result result = JUnitCore.runClasses(JUnitTestSuite.class);
-		for (Failure failure : result.getFailures()) {
-			LOGGER.info(failure.toString());
-			
-		}
-		LOGGER.info(result.wasSuccessful());
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.logging;
+
+import org.junit.runner.JUnitCore;
+import org.junit.runner.Result;
+import org.junit.runner.notification.Failure;
+import org.apache.log4j.Logger;
+
+public class TestRunner {
+	private static final Logger LOGGER = Logger.getLogger(TestRunner.class);
+
+	public static void main(String[] args) {
+		// TODO Auto-generated method stub
+		Result result = JUnitCore.runClasses(JUnitTestSuite.class);
+		for (Failure failure : result.getFailures()) {
+			LOGGER.info(failure.toString());
+			
+		}
+		LOGGER.info(result.wasSuccessful());
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/test/clients/ConsolePublisherTest.java b/src/test/java/org/onap/dmaap/mr/test/clients/ConsolePublisherTest.java
similarity index 97%
rename from src/test/java/com/att/nsa/mr/test/clients/ConsolePublisherTest.java
rename to src/test/java/org/onap/dmaap/mr/test/clients/ConsolePublisherTest.java
index 5ccd10c..218e6c8 100644
--- a/src/test/java/com/att/nsa/mr/test/clients/ConsolePublisherTest.java
+++ b/src/test/java/org/onap/dmaap/mr/test/clients/ConsolePublisherTest.java
@@ -1,55 +1,55 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.test.clients;
-
-import static org.junit.Assert.assertTrue;
-
-import java.io.IOException;
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-
-public class ConsolePublisherTest {
-
-	@Before
-	public void setUp() throws Exception {
-
-	}
-
-	@After
-	public void tearDown() throws Exception {
-
-	}
-
-	@Test
-	public void testMain() {
-
-		try {
-			ConsolePublisher.main(null);
-		} catch (Exception e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		}
-		assertTrue(true);
-
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.test.clients;
+
+import static org.junit.Assert.assertTrue;
+
+import java.io.IOException;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+
+public class ConsolePublisherTest {
+
+	@Before
+	public void setUp() throws Exception {
+
+	}
+
+	@After
+	public void tearDown() throws Exception {
+
+	}
+
+	@Test
+	public void testMain() {
+
+		try {
+			ConsolePublisher.main(null);
+		} catch (Exception e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+		assertTrue(true);
+
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/test/clients/JUnitTestSuite.java b/src/test/java/org/onap/dmaap/mr/test/clients/JUnitTestSuite.java
similarity index 97%
rename from src/test/java/com/att/nsa/mr/test/clients/JUnitTestSuite.java
rename to src/test/java/org/onap/dmaap/mr/test/clients/JUnitTestSuite.java
index 49e22de..eb0ca3d 100644
--- a/src/test/java/com/att/nsa/mr/test/clients/JUnitTestSuite.java
+++ b/src/test/java/org/onap/dmaap/mr/test/clients/JUnitTestSuite.java
@@ -1,45 +1,45 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.test.clients;
-
-import junit.framework.TestSuite;
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-import org.junit.runners.Suite.SuiteClasses;
-import org.apache.log4j.Logger;
-
-@RunWith(Suite.class)
-@SuiteClasses({ SimpleExamplePublisherTest.class, ProtocolTypeConstantsTest.class,
-	SampleConsumerTest.class, SamplePublisherTest.class, SimpleExampleConsumerTest.class, ConsolePublisherTest.class,
-	SimpleExamplePublisherWithResponseTest.class, SimpleExampleConsumerWithReturnResponseTest.class,})
-
-public class JUnitTestSuite {
-	private static final Logger LOGGER = Logger.getLogger(JUnitTestSuite.class);
-
-	public static void main(String[] args) {
-		LOGGER.info("Running the test suite");
-		
-		TestSuite tstSuite = new TestSuite();
-		LOGGER.info("Total Test Counts " + tstSuite.countTestCases());
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.test.clients;
+
+import junit.framework.TestSuite;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Suite;
+import org.junit.runners.Suite.SuiteClasses;
+import org.apache.log4j.Logger;
+
+@RunWith(Suite.class)
+@SuiteClasses({ SimpleExamplePublisherTest.class, ProtocolTypeConstantsTest.class,
+	SampleConsumerTest.class, SamplePublisherTest.class, SimpleExampleConsumerTest.class, ConsolePublisherTest.class,
+	SimpleExamplePublisherWithResponseTest.class, SimpleExampleConsumerWithReturnResponseTest.class,})
+
+public class JUnitTestSuite {
+	private static final Logger LOGGER = Logger.getLogger(JUnitTestSuite.class);
+
+	public static void main(String[] args) {
+		LOGGER.info("Running the test suite");
+		
+		TestSuite tstSuite = new TestSuite();
+		LOGGER.info("Total Test Counts " + tstSuite.countTestCases());
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/test/clients/ProtocolTypeConstantsTest.java b/src/test/java/org/onap/dmaap/mr/test/clients/ProtocolTypeConstantsTest.java
similarity index 97%
rename from src/test/java/com/att/nsa/mr/test/clients/ProtocolTypeConstantsTest.java
rename to src/test/java/org/onap/dmaap/mr/test/clients/ProtocolTypeConstantsTest.java
index ce4b72c..52310bf 100644
--- a/src/test/java/com/att/nsa/mr/test/clients/ProtocolTypeConstantsTest.java
+++ b/src/test/java/org/onap/dmaap/mr/test/clients/ProtocolTypeConstantsTest.java
@@ -1,61 +1,61 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.test.clients;
-
-import static org.junit.Assert.assertTrue;
-
-import java.io.IOException;
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
-
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-
-public class ProtocolTypeConstantsTest {
-	private ProtocolTypeConstants constants = null;
-
-	@Before
-	public void setUp() throws Exception {
-		// constants = new ProtocolTypeConstants();
-
-	}
-
-	@After
-	public void tearDown() throws Exception {
-
-	}
-
-	@Test
-	public void testGetValue() {
-
-		try {
-			constants.getValue();
-		} catch (Exception e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		}
-		assertTrue(true);
-
-	}
-	
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.test.clients;
+
+import static org.junit.Assert.assertTrue;
+
+import java.io.IOException;
+import java.lang.reflect.InvocationTargetException;
+import java.lang.reflect.Method;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+
+public class ProtocolTypeConstantsTest {
+	private ProtocolTypeConstants constants = null;
+
+	@Before
+	public void setUp() throws Exception {
+		// constants = new ProtocolTypeConstants();
+
+	}
+
+	@After
+	public void tearDown() throws Exception {
+
+	}
+
+	@Test
+	public void testGetValue() {
+
+		try {
+			constants.getValue();
+		} catch (Exception e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+		assertTrue(true);
+
+	}
+	
+
+}
diff --git a/src/test/java/com/att/nsa/mr/test/clients/SampleConsumerTest.java b/src/test/java/org/onap/dmaap/mr/test/clients/SampleConsumerTest.java
similarity index 97%
rename from src/test/java/com/att/nsa/mr/test/clients/SampleConsumerTest.java
rename to src/test/java/org/onap/dmaap/mr/test/clients/SampleConsumerTest.java
index f950fc6..6c5d93f 100644
--- a/src/test/java/com/att/nsa/mr/test/clients/SampleConsumerTest.java
+++ b/src/test/java/org/onap/dmaap/mr/test/clients/SampleConsumerTest.java
@@ -1,54 +1,54 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.test.clients;
-
-import static org.junit.Assert.assertTrue;
-
-import java.io.IOException;
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-
-public class SampleConsumerTest {
-
-	@Before
-	public void setUp() throws Exception {
-
-	}
-
-	@After
-	public void tearDown() throws Exception {
-
-	}
-
-	@Test
-	public void testMain() {
-
-		try {
-			SampleConsumer.main( new String[0]);
-		} catch (Exception e) {
-			assertTrue(true);
-		}
-		assertTrue(true);
-
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.test.clients;
+
+import static org.junit.Assert.assertTrue;
+
+import java.io.IOException;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+
+public class SampleConsumerTest {
+
+	@Before
+	public void setUp() throws Exception {
+
+	}
+
+	@After
+	public void tearDown() throws Exception {
+
+	}
+
+	@Test
+	public void testMain() {
+
+		try {
+			SampleConsumer.main( new String[0]);
+		} catch (Exception e) {
+			assertTrue(true);
+		}
+		assertTrue(true);
+
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/test/clients/SamplePublisherTest.java b/src/test/java/org/onap/dmaap/mr/test/clients/SamplePublisherTest.java
similarity index 97%
rename from src/test/java/com/att/nsa/mr/test/clients/SamplePublisherTest.java
rename to src/test/java/org/onap/dmaap/mr/test/clients/SamplePublisherTest.java
index 5ad4407..3a012a7 100644
--- a/src/test/java/com/att/nsa/mr/test/clients/SamplePublisherTest.java
+++ b/src/test/java/org/onap/dmaap/mr/test/clients/SamplePublisherTest.java
@@ -1,55 +1,55 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.test.clients;
-
-import static org.junit.Assert.assertTrue;
-
-import java.io.IOException;
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-
-public class SamplePublisherTest {
-
-	@Before
-	public void setUp() throws Exception {
-
-	}
-
-	@After
-	public void tearDown() throws Exception {
-
-	}
-
-	@Test
-	public void testMain() {
-
-		try {
-			SamplePublisher.main( new String[0]);
-		} catch (Exception e) {
-			// TODO Auto-generated catch block
-			assertTrue(true);
-		}
-		assertTrue(true);
-
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.test.clients;
+
+import static org.junit.Assert.assertTrue;
+
+import java.io.IOException;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+
+public class SamplePublisherTest {
+
+	@Before
+	public void setUp() throws Exception {
+
+	}
+
+	@After
+	public void tearDown() throws Exception {
+
+	}
+
+	@Test
+	public void testMain() {
+
+		try {
+			SamplePublisher.main( new String[0]);
+		} catch (Exception e) {
+			// TODO Auto-generated catch block
+			assertTrue(true);
+		}
+		assertTrue(true);
+
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/test/clients/SimpleExampleConsumerTest.java b/src/test/java/org/onap/dmaap/mr/test/clients/SimpleExampleConsumerTest.java
similarity index 97%
rename from src/test/java/com/att/nsa/mr/test/clients/SimpleExampleConsumerTest.java
rename to src/test/java/org/onap/dmaap/mr/test/clients/SimpleExampleConsumerTest.java
index 1887ff9..310ea45 100644
--- a/src/test/java/com/att/nsa/mr/test/clients/SimpleExampleConsumerTest.java
+++ b/src/test/java/org/onap/dmaap/mr/test/clients/SimpleExampleConsumerTest.java
@@ -1,55 +1,55 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.test.clients;
-
-import static org.junit.Assert.assertTrue;
-
-import java.io.IOException;
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-
-public class SimpleExampleConsumerTest {
-
-	@Before
-	public void setUp() throws Exception {
-
-	}
-
-	@After
-	public void tearDown() throws Exception {
-
-	}
-
-	@Test
-	public void testMain() {
-
-		try {
-			SimpleExampleConsumer.main(null);
-		} catch (Exception e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		}
-		assertTrue(true);
-
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.test.clients;
+
+import static org.junit.Assert.assertTrue;
+
+import java.io.IOException;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+
+public class SimpleExampleConsumerTest {
+
+	@Before
+	public void setUp() throws Exception {
+
+	}
+
+	@After
+	public void tearDown() throws Exception {
+
+	}
+
+	@Test
+	public void testMain() {
+
+		try {
+			SimpleExampleConsumer.main(null);
+		} catch (Exception e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+		assertTrue(true);
+
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/test/clients/SimpleExampleConsumerWithReturnResponseTest.java b/src/test/java/org/onap/dmaap/mr/test/clients/SimpleExampleConsumerWithReturnResponseTest.java
similarity index 97%
rename from src/test/java/com/att/nsa/mr/test/clients/SimpleExampleConsumerWithReturnResponseTest.java
rename to src/test/java/org/onap/dmaap/mr/test/clients/SimpleExampleConsumerWithReturnResponseTest.java
index f6f2deb..3c3b3d7 100644
--- a/src/test/java/com/att/nsa/mr/test/clients/SimpleExampleConsumerWithReturnResponseTest.java
+++ b/src/test/java/org/onap/dmaap/mr/test/clients/SimpleExampleConsumerWithReturnResponseTest.java
@@ -1,54 +1,54 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.test.clients;
-
-import static org.junit.Assert.assertTrue;
-
-import java.io.IOException;
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-
-public class SimpleExampleConsumerWithReturnResponseTest {
-
-	@Before
-	public void setUp() throws Exception {
-
-	}
-
-	@After
-	public void tearDown() throws Exception {
-
-	}
-
-	@Test
-	public void testMain() {
-
-		try {
-			SimpleExampleConsumerWithReturnResponse.main(null);
-		} catch (Exception e) {
-			// TODO Auto-generated catch block			e.printStackTrace();
-		}
-		assertTrue(true);
-
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.test.clients;
+
+import static org.junit.Assert.assertTrue;
+
+import java.io.IOException;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+
+public class SimpleExampleConsumerWithReturnResponseTest {
+
+	@Before
+	public void setUp() throws Exception {
+
+	}
+
+	@After
+	public void tearDown() throws Exception {
+
+	}
+
+	@Test
+	public void testMain() {
+
+		try {
+			SimpleExampleConsumerWithReturnResponse.main(null);
+		} catch (Exception e) {
+			// TODO Auto-generated catch block			e.printStackTrace();
+		}
+		assertTrue(true);
+
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/test/clients/SimpleExamplePublisherTest.java b/src/test/java/org/onap/dmaap/mr/test/clients/SimpleExamplePublisherTest.java
similarity index 97%
rename from src/test/java/com/att/nsa/mr/test/clients/SimpleExamplePublisherTest.java
rename to src/test/java/org/onap/dmaap/mr/test/clients/SimpleExamplePublisherTest.java
index b30d523..43faf5e 100644
--- a/src/test/java/com/att/nsa/mr/test/clients/SimpleExamplePublisherTest.java
+++ b/src/test/java/org/onap/dmaap/mr/test/clients/SimpleExamplePublisherTest.java
@@ -1,80 +1,80 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.test.clients;
-
-import static org.junit.Assert.assertTrue;
-
-import java.io.IOException;
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-
-public class SimpleExamplePublisherTest {
-	private SimpleExamplePublisher pub = null;
-
-	@Before
-	public void setUp() throws Exception {
-		pub = new SimpleExamplePublisher();
-
-	}
-
-	@After
-	public void tearDown() throws Exception {
-
-	}
-
-	@Test
-	public void testPublishMessage() {
-		try {
-			pub.publishMessage("/producer");
-		} catch (NullPointerException e) {
-			assertTrue(true);
-		} catch (IOException e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		} catch (InterruptedException e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		} catch (Exception e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		}
-
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testMain() {
-
-		try {
-			SimpleExamplePublisher.main(null);
-		} catch (Exception e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		}
-		assertTrue(true);
-
-	}
-
-	
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.test.clients;
+
+import static org.junit.Assert.assertTrue;
+
+import java.io.IOException;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+
+public class SimpleExamplePublisherTest {
+	private SimpleExamplePublisher pub = null;
+
+	@Before
+	public void setUp() throws Exception {
+		pub = new SimpleExamplePublisher();
+
+	}
+
+	@After
+	public void tearDown() throws Exception {
+
+	}
+
+	@Test
+	public void testPublishMessage() {
+		try {
+			pub.publishMessage("/producer");
+		} catch (NullPointerException e) {
+			assertTrue(true);
+		} catch (IOException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		} catch (InterruptedException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		} catch (Exception e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testMain() {
+
+		try {
+			SimpleExamplePublisher.main(null);
+		} catch (Exception e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+		assertTrue(true);
+
+	}
+
+	
+
+}
diff --git a/src/test/java/com/att/nsa/mr/test/clients/SimpleExamplePublisherWithResponseTest.java b/src/test/java/org/onap/dmaap/mr/test/clients/SimpleExamplePublisherWithResponseTest.java
similarity index 97%
rename from src/test/java/com/att/nsa/mr/test/clients/SimpleExamplePublisherWithResponseTest.java
rename to src/test/java/org/onap/dmaap/mr/test/clients/SimpleExamplePublisherWithResponseTest.java
index d408a33..44dd7cf 100644
--- a/src/test/java/com/att/nsa/mr/test/clients/SimpleExamplePublisherWithResponseTest.java
+++ b/src/test/java/org/onap/dmaap/mr/test/clients/SimpleExamplePublisherWithResponseTest.java
@@ -1,68 +1,68 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.test.clients;
-
-import static org.junit.Assert.assertTrue;
-
-import java.io.IOException;
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-
-public class SimpleExamplePublisherWithResponseTest {
-	
-	private SimpleExamplePublisherWithResponse pub = null;
-	
-	@Before
-	public void setUp() throws Exception {
-		pub = new SimpleExamplePublisherWithResponse();
-	}
-
-	@After
-	public void tearDown() throws Exception {
-
-	}
-
-	@Test
-	public void testMain() {
-
-		try {
-			SimpleExamplePublisherWithResponse.main( new String[0]);
-		} catch (Exception e) {
-			assertTrue(true);
-		}
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testPublishMessage() {
-
-		try {
-			pub.publishMessage("/producer", 100);
-		} catch (Exception e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		}
-		assertTrue(true);
-
-	}
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.test.clients;
+
+import static org.junit.Assert.assertTrue;
+
+import java.io.IOException;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+
+public class SimpleExamplePublisherWithResponseTest {
+	
+	private SimpleExamplePublisherWithResponse pub = null;
+	
+	@Before
+	public void setUp() throws Exception {
+		pub = new SimpleExamplePublisherWithResponse();
+	}
+
+	@After
+	public void tearDown() throws Exception {
+
+	}
+
+	@Test
+	public void testMain() {
+
+		try {
+			SimpleExamplePublisherWithResponse.main( new String[0]);
+		} catch (Exception e) {
+			assertTrue(true);
+		}
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testPublishMessage() {
+
+		try {
+			pub.publishMessage("/producer", 100);
+		} catch (Exception e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+		assertTrue(true);
+
+	}
+}
diff --git a/src/test/java/com/att/nsa/mr/dme/client/TestRunner.java b/src/test/java/org/onap/dmaap/mr/test/clients/TestRunner.java
similarity index 97%
copy from src/test/java/com/att/nsa/mr/dme/client/TestRunner.java
copy to src/test/java/org/onap/dmaap/mr/test/clients/TestRunner.java
index 08be6da..7e3d724 100644
--- a/src/test/java/com/att/nsa/mr/dme/client/TestRunner.java
+++ b/src/test/java/org/onap/dmaap/mr/test/clients/TestRunner.java
@@ -1,41 +1,41 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.dme.client;
-
-import org.junit.runner.JUnitCore;
-import org.junit.runner.Result;
-import org.junit.runner.notification.Failure;
-import org.apache.log4j.Logger;
-
-public class TestRunner {
-	private static final Logger LOGGER = Logger.getLogger(TestRunner.class);
-
-	public static void main(String[] args) {
-		// TODO Auto-generated method stub
-		Result result = JUnitCore.runClasses(JUnitTestSuite.class);
-		for (Failure failure : result.getFailures()) {
-			LOGGER.info(failure.toString());
-			
-		}
-		LOGGER.info(result.wasSuccessful());
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.test.clients;
+
+import org.junit.runner.JUnitCore;
+import org.junit.runner.Result;
+import org.junit.runner.notification.Failure;
+import org.apache.log4j.Logger;
+
+public class TestRunner {
+	private static final Logger LOGGER = Logger.getLogger(TestRunner.class);
+
+	public static void main(String[] args) {
+		// TODO Auto-generated method stub
+		Result result = JUnitCore.runClasses(JUnitTestSuite.class);
+		for (Failure failure : result.getFailures()) {
+			LOGGER.info(failure.toString());
+			
+		}
+		LOGGER.info(result.wasSuccessful());
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/test/support/JUnitTestSuite.java b/src/test/java/org/onap/dmaap/mr/test/support/JUnitTestSuite.java
similarity index 97%
rename from src/test/java/com/att/nsa/mr/test/support/JUnitTestSuite.java
rename to src/test/java/org/onap/dmaap/mr/test/support/JUnitTestSuite.java
index 8d18e1c..6c2e0fc 100644
--- a/src/test/java/com/att/nsa/mr/test/support/JUnitTestSuite.java
+++ b/src/test/java/org/onap/dmaap/mr/test/support/JUnitTestSuite.java
@@ -1,43 +1,43 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.test.support;
-
-import junit.framework.TestSuite;
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-import org.junit.runners.Suite.SuiteClasses;
-import org.apache.log4j.Logger;
-
-@RunWith(Suite.class)
-@SuiteClasses({ MRBatchingPublisherMockTest.class, MRConsumerMockTest.class,})
-
-public class JUnitTestSuite {
-	private static final Logger LOGGER = Logger.getLogger(JUnitTestSuite.class);
-
-	public static void main(String[] args) {
-		LOGGER.info("Running the test suite");
-		
-		TestSuite tstSuite = new TestSuite();
-		LOGGER.info("Total Test Counts " + tstSuite.countTestCases());
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.test.support;
+
+import junit.framework.TestSuite;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Suite;
+import org.junit.runners.Suite.SuiteClasses;
+import org.apache.log4j.Logger;
+
+@RunWith(Suite.class)
+@SuiteClasses({ MRBatchingPublisherMockTest.class, MRConsumerMockTest.class,})
+
+public class JUnitTestSuite {
+	private static final Logger LOGGER = Logger.getLogger(JUnitTestSuite.class);
+
+	public static void main(String[] args) {
+		LOGGER.info("Running the test suite");
+		
+		TestSuite tstSuite = new TestSuite();
+		LOGGER.info("Total Test Counts " + tstSuite.countTestCases());
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/test/support/MRBatchingPublisherMockTest.java b/src/test/java/org/onap/dmaap/mr/test/support/MRBatchingPublisherMockTest.java
similarity index 93%
rename from src/test/java/com/att/nsa/mr/test/support/MRBatchingPublisherMockTest.java
rename to src/test/java/org/onap/dmaap/mr/test/support/MRBatchingPublisherMockTest.java
index 3666c25..1d6bd7c 100644
--- a/src/test/java/com/att/nsa/mr/test/support/MRBatchingPublisherMockTest.java
+++ b/src/test/java/org/onap/dmaap/mr/test/support/MRBatchingPublisherMockTest.java
@@ -1,191 +1,191 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.test.support;
-
-import static org.junit.Assert.assertTrue;
-
-import java.lang.reflect.Constructor;
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
-import java.util.ArrayList;
-import java.util.concurrent.TimeUnit;
-
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-
-import com.att.nsa.mr.client.HostSelector;
-import com.att.nsa.mr.client.MRPublisher.message;
-import com.att.nsa.mr.test.support.MRBatchingPublisherMock.Listener;
-
-public class MRBatchingPublisherMockTest {
-	private MRBatchingPublisherMock pub = null;
-
-	private MRBatchingPublisherMock.Entry entry = null;
-
-	@Before
-	public void setUp() throws Exception {
-		pub = new MRBatchingPublisherMock();
-		entry = pub.new Entry("partition", "msg");
-
-	}
-
-	@After
-	public void tearDown() throws Exception {
-
-	}
-
-	@Test
-	public void testToString() {
-
-		entry.toString();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testAddListener() {
-
-		pub.addListener(null);
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testGetCaptures() {
-
-		pub.getCaptures();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testGetCaptures2() {
-
-		pub.getCaptures(null);
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testReceived() {
-
-		pub.received();
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testResend() {
-
-		pub.reset();
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testSend() {
-
-		pub.send("partition", "msg");
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testSend2() {
-
-		pub.send("msg");
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testSend3() {
-		//sending message m obj
-		pub.send(new ArrayList<message>());
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testSend4() {
-		//sending collection of message m objects
-		pub.send(new message("partition", "msg"));
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testSendBatchWithResponse() {
-
-		pub.sendBatchWithResponse();
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testLogTo() {
-
-		pub.logTo(null);
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testClearApiCredentials() {
-
-		pub.clearApiCredentials();
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testSetApiCredentials() {
-
-		pub.setApiCredentials("apikey", "apisecret");
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testClose() {
-
-		pub.close();
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testClose2() {
-
-		pub.close(100, null);
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testGetPendingMessageCount() {
-
-		pub.getPendingMessageCount();
-		assertTrue(true);
-
-	}
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.test.support;
+
+import static org.junit.Assert.assertTrue;
+
+import java.lang.reflect.Constructor;
+import java.lang.reflect.InvocationTargetException;
+import java.lang.reflect.Method;
+import java.util.ArrayList;
+import java.util.concurrent.TimeUnit;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+
+import org.onap.dmaap.mr.client.HostSelector;
+import org.onap.dmaap.mr.client.MRPublisher.message;
+import org.onap.dmaap.mr.test.support.MRBatchingPublisherMock.Listener;
+
+public class MRBatchingPublisherMockTest {
+	private MRBatchingPublisherMock pub = null;
+
+	private MRBatchingPublisherMock.Entry entry = null;
+
+	@Before
+	public void setUp() throws Exception {
+		pub = new MRBatchingPublisherMock();
+		entry = pub.new Entry("partition", "msg");
+
+	}
+
+	@After
+	public void tearDown() throws Exception {
+
+	}
+
+	@Test
+	public void testToString() {
+
+		entry.toString();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testAddListener() {
+
+		pub.addListener(null);
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testGetCaptures() {
+
+		pub.getCaptures();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testGetCaptures2() {
+
+		pub.getCaptures(null);
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testReceived() {
+
+		pub.received();
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testResend() {
+
+		pub.reset();
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testSend() {
+
+		pub.send("partition", "msg");
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testSend2() {
+
+		pub.send("msg");
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testSend3() {
+		//sending message m obj
+		pub.send(new ArrayList<message>());
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testSend4() {
+		//sending collection of message m objects
+		pub.send(new message("partition", "msg"));
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testSendBatchWithResponse() {
+
+		pub.sendBatchWithResponse();
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testLogTo() {
+
+		pub.logTo(null);
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testClearApiCredentials() {
+
+		pub.clearApiCredentials();
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testSetApiCredentials() {
+
+		pub.setApiCredentials("apikey", "apisecret");
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testClose() {
+
+		pub.close();
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testClose2() {
+
+		pub.close(100, null);
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testGetPendingMessageCount() {
+
+		pub.getPendingMessageCount();
+		assertTrue(true);
+
+	}
+}
diff --git a/src/test/java/com/att/nsa/mr/test/support/MRConsumerMockTest.java b/src/test/java/org/onap/dmaap/mr/test/support/MRConsumerMockTest.java
similarity index 93%
rename from src/test/java/com/att/nsa/mr/test/support/MRConsumerMockTest.java
rename to src/test/java/org/onap/dmaap/mr/test/support/MRConsumerMockTest.java
index 2a4f50a..9ae49e0 100644
--- a/src/test/java/com/att/nsa/mr/test/support/MRConsumerMockTest.java
+++ b/src/test/java/org/onap/dmaap/mr/test/support/MRConsumerMockTest.java
@@ -1,174 +1,174 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.test.support;
-
-import static org.junit.Assert.assertTrue;
-
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.concurrent.TimeUnit;
-
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-
-import com.att.nsa.mr.client.HostSelector;
-import com.att.nsa.mr.client.MRPublisher.message;
-import com.att.nsa.mr.test.support.MRBatchingPublisherMock.Entry;
-
-public class MRConsumerMockTest {
-	private MRConsumerMock cons = null;
-	private MRConsumerMock.Entry entry = null;
-
-	@Before
-	public void setUp() throws Exception {
-		cons = new MRConsumerMock();
-		entry = cons.new Entry(100, 200, "statusMsg");
-
-	}
-
-	@After
-	public void tearDown() throws Exception {
-
-	}
-
-	@Test
-	public void testClose() {
-
-		cons.close();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testRun() {
-		try {
-			entry.run();
-		} catch (IOException e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		}
-
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testSetApiCredentials() {
-		cons.setApiCredentials("apikey", "apisecret");
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testClearApiCredentials() {
-		cons.clearApiCredentials();
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testAdd() {
-		cons.add(entry);
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testAddImmediateMsg() {
-		cons.addImmediateMsg("ImmediateMsg");
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testAddDelayedMsg() {
-		cons.addDelayedMsg(100, "msg");
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testAddImmediateMsgGroup() {
-		cons.addImmediateMsgGroup(new ArrayList<String>());
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testAddDelayedMsgGroup() {
-		cons.addDelayedMsgGroup(100,new ArrayList<String>());
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testAddImmediateError() {
-		cons.addImmediateError(200, "OK");
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testFetch() {
-		try {
-			cons.fetch();
-		} catch (IOException e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		}
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testFetch2() {
-		try {
-			cons.fetch(100, 200);
-		} catch (IOException e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		}
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testLogTo() {
-		cons.logTo(null);
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testFetchWithReturnConsumerResponse() {
-		cons.fetchWithReturnConsumerResponse();
-		assertTrue(true);
-
-	}
-	
-	@Test
-	public void testGetchWithReturnConsumerResponse() {
-		cons.fetchWithReturnConsumerResponse(100,200);
-		assertTrue(true);
-
-	}
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.test.support;
+
+import static org.junit.Assert.assertTrue;
+
+import java.io.IOException;
+import java.util.ArrayList;
+import java.util.concurrent.TimeUnit;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+
+import org.onap.dmaap.mr.client.HostSelector;
+import org.onap.dmaap.mr.client.MRPublisher.message;
+import org.onap.dmaap.mr.test.support.MRBatchingPublisherMock.Entry;
+
+public class MRConsumerMockTest {
+	private MRConsumerMock cons = null;
+	private MRConsumerMock.Entry entry = null;
+
+	@Before
+	public void setUp() throws Exception {
+		cons = new MRConsumerMock();
+		entry = cons.new Entry(100, 200, "statusMsg");
+
+	}
+
+	@After
+	public void tearDown() throws Exception {
+
+	}
+
+	@Test
+	public void testClose() {
+
+		cons.close();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testRun() {
+		try {
+			entry.run();
+		} catch (IOException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testSetApiCredentials() {
+		cons.setApiCredentials("apikey", "apisecret");
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testClearApiCredentials() {
+		cons.clearApiCredentials();
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testAdd() {
+		cons.add(entry);
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testAddImmediateMsg() {
+		cons.addImmediateMsg("ImmediateMsg");
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testAddDelayedMsg() {
+		cons.addDelayedMsg(100, "msg");
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testAddImmediateMsgGroup() {
+		cons.addImmediateMsgGroup(new ArrayList<String>());
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testAddDelayedMsgGroup() {
+		cons.addDelayedMsgGroup(100,new ArrayList<String>());
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testAddImmediateError() {
+		cons.addImmediateError(200, "OK");
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testFetch() {
+		try {
+			cons.fetch();
+		} catch (IOException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testFetch2() {
+		try {
+			cons.fetch(100, 200);
+		} catch (IOException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testLogTo() {
+		cons.logTo(null);
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testFetchWithReturnConsumerResponse() {
+		cons.fetchWithReturnConsumerResponse();
+		assertTrue(true);
+
+	}
+	
+	@Test
+	public void testGetchWithReturnConsumerResponse() {
+		cons.fetchWithReturnConsumerResponse(100,200);
+		assertTrue(true);
+
+	}
+}
diff --git a/src/test/java/com/att/nsa/mr/dme/client/TestRunner.java b/src/test/java/org/onap/dmaap/mr/test/support/TestRunner.java
similarity index 97%
copy from src/test/java/com/att/nsa/mr/dme/client/TestRunner.java
copy to src/test/java/org/onap/dmaap/mr/test/support/TestRunner.java
index 08be6da..0a09a14 100644
--- a/src/test/java/com/att/nsa/mr/dme/client/TestRunner.java
+++ b/src/test/java/org/onap/dmaap/mr/test/support/TestRunner.java
@@ -1,41 +1,41 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.dme.client;
-
-import org.junit.runner.JUnitCore;
-import org.junit.runner.Result;
-import org.junit.runner.notification.Failure;
-import org.apache.log4j.Logger;
-
-public class TestRunner {
-	private static final Logger LOGGER = Logger.getLogger(TestRunner.class);
-
-	public static void main(String[] args) {
-		// TODO Auto-generated method stub
-		Result result = JUnitCore.runClasses(JUnitTestSuite.class);
-		for (Failure failure : result.getFailures()) {
-			LOGGER.info(failure.toString());
-			
-		}
-		LOGGER.info(result.wasSuccessful());
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.test.support;
+
+import org.junit.runner.JUnitCore;
+import org.junit.runner.Result;
+import org.junit.runner.notification.Failure;
+import org.apache.log4j.Logger;
+
+public class TestRunner {
+	private static final Logger LOGGER = Logger.getLogger(TestRunner.class);
+
+	public static void main(String[] args) {
+		// TODO Auto-generated method stub
+		Result result = JUnitCore.runClasses(JUnitTestSuite.class);
+		for (Failure failure : result.getFailures()) {
+			LOGGER.info(failure.toString());
+			
+		}
+		LOGGER.info(result.wasSuccessful());
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/tools/ApiKeyCommandTest.java b/src/test/java/org/onap/dmaap/mr/tools/ApiKeyCommandTest.java
similarity index 95%
rename from src/test/java/com/att/nsa/mr/tools/ApiKeyCommandTest.java
rename to src/test/java/org/onap/dmaap/mr/tools/ApiKeyCommandTest.java
index e5bd722..e022bf5 100644
--- a/src/test/java/com/att/nsa/mr/tools/ApiKeyCommandTest.java
+++ b/src/test/java/org/onap/dmaap/mr/tools/ApiKeyCommandTest.java
@@ -1,217 +1,217 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.tools;
-
-import static org.junit.Assert.assertTrue;
-
-import java.io.IOException;
-import java.io.PrintStream;
-import java.util.Arrays;
-import java.util.Iterator;
-import java.util.List;
-
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.InjectMocks;
-import org.mockito.Mock;
-import org.mockito.MockitoAnnotations;
-import org.powermock.api.mockito.PowerMockito;
-import org.powermock.core.classloader.annotations.PrepareForTest;
-import org.powermock.modules.junit4.PowerMockRunner;
-
-import com.att.nsa.apiClient.credentials.ApiCredential;
-import com.att.nsa.apiClient.http.HttpException;
-import com.att.nsa.apiClient.http.HttpObjectNotFoundException;
-import com.att.nsa.cmdtool.CommandNotReadyException;
-import com.att.nsa.mr.client.MRClient.MRApiException;
-import com.att.nsa.mr.client.MRClientFactory;
-import com.att.nsa.mr.client.MRIdentityManager;
-import com.att.nsa.mr.client.MRIdentityManager.ApiKey;
-
-@RunWith(PowerMockRunner.class)
-@PrepareForTest({ MRClientFactory.class })
-public class ApiKeyCommandTest {
-
-	@InjectMocks
-	private ApiKeyCommand command;
-	@Mock
-	private MRIdentityManager tm;
-	@Mock
-	private ApiKey ti;
-	@Mock
-	private ApiKey key;
-	@Mock
-	private ApiCredential ac;
-	@Mock
-	private PrintStream printStream;
-
-	@Before
-	public void setUp() throws Exception {
-		MockitoAnnotations.initMocks(this);
-		PowerMockito.mockStatic(MRClientFactory.class);
-		PowerMockito.when(MRClientFactory.createIdentityManager(Arrays.asList("localhost"), null, null)).thenReturn(tm);
-		PowerMockito.when(tm.getApiKey("testtopic")).thenReturn(key);
-		PowerMockito.when(tm.createApiKey("testtopic", "1")).thenReturn(ac);
-
-	}
-
-	@After
-	public void tearDown() throws Exception {
-
-	}
-
-	@Test
-	public void testGetMatches() {
-
-		command.getMatches();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testCheckReady() {
-
-		try {
-			command.checkReady(new MRCommandContext());
-		} catch (CommandNotReadyException e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		}
-		assertTrue(true);
-
-	}
-
-	 @Test
-	public void testExecute() {
-
-		String[] parts1 = { "create", "testtopic", "1" };
-		String[] parts2 = { "list", "testtopic", "1" };
-		String[] parts3 = { "revoke", "write", "read" };
-		List<String[]> parts = Arrays.asList(parts1, parts2, parts3);
-		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
-			String[] part = (String[]) iterator.next();
-
-			try {
-				command.execute(part, new MRCommandContext(), printStream);
-			} catch (CommandNotReadyException e) {
-				// TODO Auto-generated catch block
-				e.printStackTrace();
-			}
-			assertTrue(true);
-
-		}
-	}
-
-	 @Test
-	public void testExecute_error1() throws HttpObjectNotFoundException, HttpException, MRApiException, IOException {
-		PowerMockito.when(tm.getApiKey("testtopic")).thenThrow(new IOException("error"));
-		String[] parts1 = { "create", "testtopic", "1" };
-		String[] parts2 = { "list", "testtopic", "1" };
-		String[] parts3 = { "revoke", "write", "read" };
-		List<String[]> parts = Arrays.asList(parts1, parts2, parts3);
-		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
-			String[] part = (String[]) iterator.next();
-
-			try {
-				command.execute(part, new MRCommandContext(), printStream);
-			} catch (CommandNotReadyException e) {
-				// TODO Auto-generated catch block
-				e.printStackTrace();
-			}
-			assertTrue(true);
-		}
-
-	}
-
-	 @Test
-	public void testExecute_error2() throws HttpObjectNotFoundException, HttpException, MRApiException, IOException {
-		PowerMockito.when(tm.getApiKey("testtopic")).thenThrow(new MRApiException("error"));
-		String[] parts1 = { "create", "testtopic", "1" };
-		String[] parts2 = { "list", "testtopic", "1" };
-		String[] parts3 = { "revoke", "write", "read" };
-		List<String[]> parts = Arrays.asList(parts1, parts2, parts3);
-		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
-			String[] part = (String[]) iterator.next();
-
-			try {
-				command.execute(part, new MRCommandContext(),printStream);
-			} catch (CommandNotReadyException e) {
-				// TODO Auto-generated catch block
-				e.printStackTrace();
-			}
-			assertTrue(true);
-
-		}
-	}
-
-	 @Test
-	public void testExecute_error3() throws HttpObjectNotFoundException, HttpException, MRApiException, IOException {
-		PowerMockito.when(tm.getApiKey("testtopic")).thenThrow(new HttpException(500, "error"));
-		String[] parts1 = { "create", "testtopic", "1" };
-		String[] parts2 = { "list", "testtopic", "1" };
-		String[] parts3 = { "revoke", "write", "read" };
-		List<String[]> parts = Arrays.asList(parts1, parts2, parts3);
-		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
-			String[] part = (String[]) iterator.next();
-
-			try {
-				command.execute(part, new MRCommandContext(), printStream);
-			} catch (CommandNotReadyException e) {
-				// TODO Auto-generated catch block
-				e.printStackTrace();
-			}
-			assertTrue(true);
-		}
-
-	}
-
-	 @Test
-	public void testExecute_error4() throws HttpObjectNotFoundException, HttpException, MRApiException, IOException {
-		PowerMockito.when(tm.getApiKey("testtopic")).thenThrow(new HttpObjectNotFoundException("error"));
-		String[] parts1 = { "create", "testtopic", "1" };
-		String[] parts2 = { "list", "testtopic", "1" };
-		String[] parts3 = { "revoke", "write", "read" };
-		List<String[]> parts = Arrays.asList(parts1, parts2, parts3);
-		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
-			String[] part = (String[]) iterator.next();
-
-			try {
-				command.execute(part, new MRCommandContext(), printStream);
-			} catch (CommandNotReadyException e) {
-				// TODO Auto-generated catch block
-				e.printStackTrace();
-			}
-			assertTrue(true);
-
-		}
-	}
-
-	 @Test
-	public void testDisplayHelp() {
-
-		command.displayHelp(printStream);
-		assertTrue(true);
-
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.tools;
+
+import static org.junit.Assert.assertTrue;
+
+import java.io.IOException;
+import java.io.PrintStream;
+import java.util.Arrays;
+import java.util.Iterator;
+import java.util.List;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.mockito.InjectMocks;
+import org.mockito.Mock;
+import org.mockito.MockitoAnnotations;
+import org.powermock.api.mockito.PowerMockito;
+import org.powermock.core.classloader.annotations.PrepareForTest;
+import org.powermock.modules.junit4.PowerMockRunner;
+
+import com.att.nsa.apiClient.credentials.ApiCredential;
+import com.att.nsa.apiClient.http.HttpException;
+import com.att.nsa.apiClient.http.HttpObjectNotFoundException;
+import com.att.nsa.cmdtool.CommandNotReadyException;
+import org.onap.dmaap.mr.client.MRClient.MRApiException;
+import org.onap.dmaap.mr.client.MRClientFactory;
+import org.onap.dmaap.mr.client.MRIdentityManager;
+import org.onap.dmaap.mr.client.MRIdentityManager.ApiKey;
+
+@RunWith(PowerMockRunner.class)
+@PrepareForTest({ MRClientFactory.class })
+public class ApiKeyCommandTest {
+
+	@InjectMocks
+	private ApiKeyCommand command;
+	@Mock
+	private MRIdentityManager tm;
+	@Mock
+	private ApiKey ti;
+	@Mock
+	private ApiKey key;
+	@Mock
+	private ApiCredential ac;
+	@Mock
+	private PrintStream printStream;
+
+	@Before
+	public void setUp() throws Exception {
+		MockitoAnnotations.initMocks(this);
+		PowerMockito.mockStatic(MRClientFactory.class);
+		PowerMockito.when(MRClientFactory.createIdentityManager(Arrays.asList("localhost"), null, null)).thenReturn(tm);
+		PowerMockito.when(tm.getApiKey("testtopic")).thenReturn(key);
+		PowerMockito.when(tm.createApiKey("testtopic", "1")).thenReturn(ac);
+
+	}
+
+	@After
+	public void tearDown() throws Exception {
+
+	}
+
+	@Test
+	public void testGetMatches() {
+
+		command.getMatches();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testCheckReady() {
+
+		try {
+			command.checkReady(new MRCommandContext());
+		} catch (CommandNotReadyException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+		assertTrue(true);
+
+	}
+
+	 @Test
+	public void testExecute() {
+
+		String[] parts1 = { "create", "testtopic", "1" };
+		String[] parts2 = { "list", "testtopic", "1" };
+		String[] parts3 = { "revoke", "write", "read" };
+		List<String[]> parts = Arrays.asList(parts1, parts2, parts3);
+		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
+			String[] part = (String[]) iterator.next();
+
+			try {
+				command.execute(part, new MRCommandContext(), printStream);
+			} catch (CommandNotReadyException e) {
+				// TODO Auto-generated catch block
+				e.printStackTrace();
+			}
+			assertTrue(true);
+
+		}
+	}
+
+	 @Test
+	public void testExecute_error1() throws HttpObjectNotFoundException, HttpException, MRApiException, IOException {
+		PowerMockito.when(tm.getApiKey("testtopic")).thenThrow(new IOException("error"));
+		String[] parts1 = { "create", "testtopic", "1" };
+		String[] parts2 = { "list", "testtopic", "1" };
+		String[] parts3 = { "revoke", "write", "read" };
+		List<String[]> parts = Arrays.asList(parts1, parts2, parts3);
+		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
+			String[] part = (String[]) iterator.next();
+
+			try {
+				command.execute(part, new MRCommandContext(), printStream);
+			} catch (CommandNotReadyException e) {
+				// TODO Auto-generated catch block
+				e.printStackTrace();
+			}
+			assertTrue(true);
+		}
+
+	}
+
+	 @Test
+	public void testExecute_error2() throws HttpObjectNotFoundException, HttpException, MRApiException, IOException {
+		PowerMockito.when(tm.getApiKey("testtopic")).thenThrow(new MRApiException("error"));
+		String[] parts1 = { "create", "testtopic", "1" };
+		String[] parts2 = { "list", "testtopic", "1" };
+		String[] parts3 = { "revoke", "write", "read" };
+		List<String[]> parts = Arrays.asList(parts1, parts2, parts3);
+		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
+			String[] part = (String[]) iterator.next();
+
+			try {
+				command.execute(part, new MRCommandContext(),printStream);
+			} catch (CommandNotReadyException e) {
+				// TODO Auto-generated catch block
+				e.printStackTrace();
+			}
+			assertTrue(true);
+
+		}
+	}
+
+	 @Test
+	public void testExecute_error3() throws HttpObjectNotFoundException, HttpException, MRApiException, IOException {
+		PowerMockito.when(tm.getApiKey("testtopic")).thenThrow(new HttpException(500, "error"));
+		String[] parts1 = { "create", "testtopic", "1" };
+		String[] parts2 = { "list", "testtopic", "1" };
+		String[] parts3 = { "revoke", "write", "read" };
+		List<String[]> parts = Arrays.asList(parts1, parts2, parts3);
+		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
+			String[] part = (String[]) iterator.next();
+
+			try {
+				command.execute(part, new MRCommandContext(), printStream);
+			} catch (CommandNotReadyException e) {
+				// TODO Auto-generated catch block
+				e.printStackTrace();
+			}
+			assertTrue(true);
+		}
+
+	}
+
+	 @Test
+	public void testExecute_error4() throws HttpObjectNotFoundException, HttpException, MRApiException, IOException {
+		PowerMockito.when(tm.getApiKey("testtopic")).thenThrow(new HttpObjectNotFoundException("error"));
+		String[] parts1 = { "create", "testtopic", "1" };
+		String[] parts2 = { "list", "testtopic", "1" };
+		String[] parts3 = { "revoke", "write", "read" };
+		List<String[]> parts = Arrays.asList(parts1, parts2, parts3);
+		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
+			String[] part = (String[]) iterator.next();
+
+			try {
+				command.execute(part, new MRCommandContext(), printStream);
+			} catch (CommandNotReadyException e) {
+				// TODO Auto-generated catch block
+				e.printStackTrace();
+			}
+			assertTrue(true);
+
+		}
+	}
+
+	 @Test
+	public void testDisplayHelp() {
+
+		command.displayHelp(printStream);
+		assertTrue(true);
+
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/tools/AuthCommandTest.java b/src/test/java/org/onap/dmaap/mr/tools/AuthCommandTest.java
similarity index 98%
rename from src/test/java/com/att/nsa/mr/tools/AuthCommandTest.java
rename to src/test/java/org/onap/dmaap/mr/tools/AuthCommandTest.java
index fdb7671..9f9011a 100644
--- a/src/test/java/com/att/nsa/mr/tools/AuthCommandTest.java
+++ b/src/test/java/org/onap/dmaap/mr/tools/AuthCommandTest.java
@@ -1,113 +1,113 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.tools;
-
-import static org.junit.Assert.assertTrue;
-
-import java.io.PrintStream;
-
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.InjectMocks;
-import org.mockito.Mock;
-import org.mockito.MockitoAnnotations;
-import org.powermock.modules.junit4.PowerMockRunner;
-
-import com.att.nsa.cmdtool.CommandNotReadyException;
-
-@RunWith(PowerMockRunner.class)
-public class AuthCommandTest {
-	@InjectMocks
-	private AuthCommand command = null;
-	@Mock
-	private PrintStream printStream;
-
-	@Before
-	public void setUp() throws Exception {
-		MockitoAnnotations.initMocks(this);
-
-	}
-
-	@After
-	public void tearDown() throws Exception {
-
-	}
-
-	@Test
-	public void testGetMatches() {
-
-		command.getMatches();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testCheckReady() {
-
-		try {
-			command.checkReady(new MRCommandContext());
-		} catch (CommandNotReadyException e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		}
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testExecute() {
-
-		try {
-			String[] parts = new String[5];
-			command.execute(parts, new MRCommandContext(), printStream);
-		} catch (CommandNotReadyException e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		}
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testExecute1() {
-
-		try {
-			String[] parts = { "userName", "password" };
-			command.execute(parts, new MRCommandContext(), printStream);
-		} catch (CommandNotReadyException e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		}
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testDisplayHelp() {
-
-		command.displayHelp(printStream);
-		assertTrue(true);
-
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.tools;
+
+import static org.junit.Assert.assertTrue;
+
+import java.io.PrintStream;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.mockito.InjectMocks;
+import org.mockito.Mock;
+import org.mockito.MockitoAnnotations;
+import org.powermock.modules.junit4.PowerMockRunner;
+
+import com.att.nsa.cmdtool.CommandNotReadyException;
+
+@RunWith(PowerMockRunner.class)
+public class AuthCommandTest {
+	@InjectMocks
+	private AuthCommand command = null;
+	@Mock
+	private PrintStream printStream;
+
+	@Before
+	public void setUp() throws Exception {
+		MockitoAnnotations.initMocks(this);
+
+	}
+
+	@After
+	public void tearDown() throws Exception {
+
+	}
+
+	@Test
+	public void testGetMatches() {
+
+		command.getMatches();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testCheckReady() {
+
+		try {
+			command.checkReady(new MRCommandContext());
+		} catch (CommandNotReadyException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testExecute() {
+
+		try {
+			String[] parts = new String[5];
+			command.execute(parts, new MRCommandContext(), printStream);
+		} catch (CommandNotReadyException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testExecute1() {
+
+		try {
+			String[] parts = { "userName", "password" };
+			command.execute(parts, new MRCommandContext(), printStream);
+		} catch (CommandNotReadyException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testDisplayHelp() {
+
+		command.displayHelp(printStream);
+		assertTrue(true);
+
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/tools/ClusterCommandTest.java b/src/test/java/org/onap/dmaap/mr/tools/ClusterCommandTest.java
similarity index 98%
rename from src/test/java/com/att/nsa/mr/tools/ClusterCommandTest.java
rename to src/test/java/org/onap/dmaap/mr/tools/ClusterCommandTest.java
index cf9c1a7..0dc2f64 100644
--- a/src/test/java/com/att/nsa/mr/tools/ClusterCommandTest.java
+++ b/src/test/java/org/onap/dmaap/mr/tools/ClusterCommandTest.java
@@ -1,106 +1,106 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.tools;
-
-import static org.junit.Assert.assertTrue;
-
-import java.io.FileNotFoundException;
-import java.io.PrintStream;
-import java.util.Arrays;
-
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.InjectMocks;
-import org.mockito.Mock;
-import org.mockito.MockitoAnnotations;
-import org.powermock.api.mockito.PowerMockito;
-import org.powermock.modules.junit4.PowerMockRunner;
-
-import com.att.nsa.cmdtool.CommandNotReadyException;
-
-@RunWith(PowerMockRunner.class)
-public class ClusterCommandTest {
-	@InjectMocks
-	private ClusterCommand command;
-	@Mock
-	private MRCommandContext context;
-	@Mock
-	private PrintStream printStream;
-
-	@Before
-	public void setUp() throws Exception {
-		MockitoAnnotations.initMocks(this);
-		PowerMockito.when(context.getCluster()).thenReturn(Arrays.asList("localhost"));
-	}
-
-	@After
-	public void tearDown() throws Exception {
-
-	}
-
-	@Test
-	public void testGetMatches() {
-
-		command.getMatches();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testCheckReady() {
-
-		try {
-			command.checkReady(context);
-		} catch (CommandNotReadyException e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		}
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testExecute() throws FileNotFoundException, CommandNotReadyException {
-		String[] parts = { "create", "testtopic", "1", "1" };
-		command.execute(parts, context, printStream);
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testExecute1() throws FileNotFoundException, CommandNotReadyException {
-		String[] parts = {};
-		command.execute(parts, context, printStream);
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testDisplayHelp() {
-
-		command.displayHelp(printStream);
-		assertTrue(true);
-
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.tools;
+
+import static org.junit.Assert.assertTrue;
+
+import java.io.FileNotFoundException;
+import java.io.PrintStream;
+import java.util.Arrays;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.mockito.InjectMocks;
+import org.mockito.Mock;
+import org.mockito.MockitoAnnotations;
+import org.powermock.api.mockito.PowerMockito;
+import org.powermock.modules.junit4.PowerMockRunner;
+
+import com.att.nsa.cmdtool.CommandNotReadyException;
+
+@RunWith(PowerMockRunner.class)
+public class ClusterCommandTest {
+	@InjectMocks
+	private ClusterCommand command;
+	@Mock
+	private MRCommandContext context;
+	@Mock
+	private PrintStream printStream;
+
+	@Before
+	public void setUp() throws Exception {
+		MockitoAnnotations.initMocks(this);
+		PowerMockito.when(context.getCluster()).thenReturn(Arrays.asList("localhost"));
+	}
+
+	@After
+	public void tearDown() throws Exception {
+
+	}
+
+	@Test
+	public void testGetMatches() {
+
+		command.getMatches();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testCheckReady() {
+
+		try {
+			command.checkReady(context);
+		} catch (CommandNotReadyException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testExecute() throws FileNotFoundException, CommandNotReadyException {
+		String[] parts = { "create", "testtopic", "1", "1" };
+		command.execute(parts, context, printStream);
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testExecute1() throws FileNotFoundException, CommandNotReadyException {
+		String[] parts = {};
+		command.execute(parts, context, printStream);
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testDisplayHelp() {
+
+		command.displayHelp(printStream);
+		assertTrue(true);
+
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/tools/JUnitTestSuite.java b/src/test/java/org/onap/dmaap/mr/tools/JUnitTestSuite.java
similarity index 97%
rename from src/test/java/com/att/nsa/mr/tools/JUnitTestSuite.java
rename to src/test/java/org/onap/dmaap/mr/tools/JUnitTestSuite.java
index 6e882d4..ca79f9b 100644
--- a/src/test/java/com/att/nsa/mr/tools/JUnitTestSuite.java
+++ b/src/test/java/org/onap/dmaap/mr/tools/JUnitTestSuite.java
@@ -1,44 +1,44 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.tools;
-
-import junit.framework.TestSuite;
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-import org.junit.runners.Suite.SuiteClasses;
-import org.apache.log4j.Logger;
-
-@RunWith(Suite.class)
-@SuiteClasses({ ApiKeyCommandTest.class, AuthCommandTest.class, ClusterCommandTest.class,
-	MessageCommandTest.class, MRCommandContextTest.class, TopicCommandTest.class, TraceCommandTest.class,})
-
-public class JUnitTestSuite {
-	private static final Logger LOGGER = Logger.getLogger(JUnitTestSuite.class);
-
-	public static void main(String[] args) {
-		LOGGER.info("Running the test suite");
-		
-		TestSuite tstSuite = new TestSuite();
-		LOGGER.info("Total Test Counts " + tstSuite.countTestCases());
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.tools;
+
+import junit.framework.TestSuite;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Suite;
+import org.junit.runners.Suite.SuiteClasses;
+import org.apache.log4j.Logger;
+
+@RunWith(Suite.class)
+@SuiteClasses({ ApiKeyCommandTest.class, AuthCommandTest.class, ClusterCommandTest.class,
+	MessageCommandTest.class, MRCommandContextTest.class, TopicCommandTest.class, TraceCommandTest.class,})
+
+public class JUnitTestSuite {
+	private static final Logger LOGGER = Logger.getLogger(JUnitTestSuite.class);
+
+	public static void main(String[] args) {
+		LOGGER.info("Running the test suite");
+		
+		TestSuite tstSuite = new TestSuite();
+		LOGGER.info("Total Test Counts " + tstSuite.countTestCases());
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/tools/MRCommandContextTest.java b/src/test/java/org/onap/dmaap/mr/tools/MRCommandContextTest.java
similarity index 92%
rename from src/test/java/com/att/nsa/mr/tools/MRCommandContextTest.java
rename to src/test/java/org/onap/dmaap/mr/tools/MRCommandContextTest.java
index 23ef0a1..038e321 100644
--- a/src/test/java/com/att/nsa/mr/tools/MRCommandContextTest.java
+++ b/src/test/java/org/onap/dmaap/mr/tools/MRCommandContextTest.java
@@ -1,165 +1,165 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.tools;
-
-import static org.junit.Assert.assertTrue;
-
-import java.io.FileNotFoundException;
-import java.io.IOException;
-import java.io.PrintStream;
-import java.util.ArrayList;
-import java.util.concurrent.TimeUnit;
-
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-
-import com.att.nsa.apiClient.http.HttpTracer;
-import com.att.nsa.cmdtool.CommandNotReadyException;
-import com.att.nsa.mr.client.HostSelector;
-import com.att.nsa.mr.client.MRClient;
-import com.att.nsa.mr.client.MRPublisher.message;
-import com.att.nsa.mr.test.support.MRBatchingPublisherMock.Entry;
-
-public class MRCommandContextTest {
-	private MRCommandContext command = null;
-	private String[] parts = new String[5];
-
-	@Before
-	public void setUp() throws Exception {
-		command = new MRCommandContext();
-
-		for (int i = 0; i < parts.length; i++) {
-			parts[i] = "String" + (i + 1);
-		}
-
-	}
-
-	@After
-	public void tearDown() throws Exception {
-
-	}
-
-	@Test
-	public void testRequestShutdown() {
-
-		command.requestShutdown();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testShouldContinue() {
-
-		command.shouldContinue();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testSetAuth() {
-
-		command.setAuth("key", "pwd");
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testClearAuth() {
-
-		command.clearAuth();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testCheckClusterReady() {
-
-		command.checkClusterReady();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testGetCluster() {
-
-		command.getCluster();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testClearCluster() {
-
-		command.clearCluster();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testAddClusterHost() {
-
-		command.addClusterHost("host");
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testGetApiKey() {
-
-		command.getApiKey();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testGetApiPwd() {
-
-		command.getApiPwd();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testUseTracer() {
-
-		command.useTracer(null);
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testNoTracer() {
-
-		command.noTracer();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testApplyTracer() {
-
-		command.applyTracer(null);
-		assertTrue(true);
-
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.tools;
+
+import static org.junit.Assert.assertTrue;
+
+import java.io.FileNotFoundException;
+import java.io.IOException;
+import java.io.PrintStream;
+import java.util.ArrayList;
+import java.util.concurrent.TimeUnit;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+
+import com.att.nsa.apiClient.http.HttpTracer;
+import com.att.nsa.cmdtool.CommandNotReadyException;
+import org.onap.dmaap.mr.client.HostSelector;
+import org.onap.dmaap.mr.client.MRClient;
+import org.onap.dmaap.mr.client.MRPublisher.message;
+import org.onap.dmaap.mr.test.support.MRBatchingPublisherMock.Entry;
+
+public class MRCommandContextTest {
+	private MRCommandContext command = null;
+	private String[] parts = new String[5];
+
+	@Before
+	public void setUp() throws Exception {
+		command = new MRCommandContext();
+
+		for (int i = 0; i < parts.length; i++) {
+			parts[i] = "String" + (i + 1);
+		}
+
+	}
+
+	@After
+	public void tearDown() throws Exception {
+
+	}
+
+	@Test
+	public void testRequestShutdown() {
+
+		command.requestShutdown();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testShouldContinue() {
+
+		command.shouldContinue();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testSetAuth() {
+
+		command.setAuth("key", "pwd");
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testClearAuth() {
+
+		command.clearAuth();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testCheckClusterReady() {
+
+		command.checkClusterReady();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testGetCluster() {
+
+		command.getCluster();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testClearCluster() {
+
+		command.clearCluster();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testAddClusterHost() {
+
+		command.addClusterHost("host");
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testGetApiKey() {
+
+		command.getApiKey();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testGetApiPwd() {
+
+		command.getApiPwd();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testUseTracer() {
+
+		command.useTracer(null);
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testNoTracer() {
+
+		command.noTracer();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testApplyTracer() {
+
+		command.applyTracer(null);
+		assertTrue(true);
+
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/tools/MessageCommandTest.java b/src/test/java/org/onap/dmaap/mr/tools/MessageCommandTest.java
similarity index 96%
rename from src/test/java/com/att/nsa/mr/tools/MessageCommandTest.java
rename to src/test/java/org/onap/dmaap/mr/tools/MessageCommandTest.java
index 638d067..f32cb43 100644
--- a/src/test/java/com/att/nsa/mr/tools/MessageCommandTest.java
+++ b/src/test/java/org/onap/dmaap/mr/tools/MessageCommandTest.java
@@ -1,214 +1,214 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.tools;
-
-import static org.junit.Assert.assertTrue;
-
-import java.io.IOException;
-import java.io.PrintStream;
-import java.util.Arrays;
-import java.util.Iterator;
-import java.util.List;
-import java.util.concurrent.TimeUnit;
-
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.InjectMocks;
-import org.mockito.Mock;
-import org.mockito.MockitoAnnotations;
-import org.powermock.api.mockito.PowerMockito;
-import org.powermock.core.classloader.annotations.PrepareForTest;
-import org.powermock.modules.junit4.PowerMockRunner;
-
-import com.att.nsa.cmdtool.CommandNotReadyException;
-import com.att.nsa.mr.client.MRBatchingPublisher;
-import com.att.nsa.mr.client.MRClientFactory;
-import com.att.nsa.mr.client.MRConsumer;
-import com.att.nsa.mr.client.MRTopicManager.TopicInfo;
-
-@RunWith(PowerMockRunner.class)
-@PrepareForTest({ MRClientFactory.class, ToolsUtil.class })
-public class MessageCommandTest {
-	@InjectMocks
-	private MessageCommand command;
-	@Mock
-	private MRConsumer tm;
-	@Mock
-	private TopicInfo ti;
-	@Mock
-	private MRBatchingPublisher pub;
-	@Mock
-	private MRConsumer cc;
-	@Mock
-	private PrintStream printStream;
-
-	@Before
-	public void setUp() throws Exception {
-		MockitoAnnotations.initMocks(this);
-		PowerMockito.mockStatic(MRClientFactory.class);
-		PowerMockito.mockStatic(ToolsUtil.class);
-		PowerMockito.when(MRClientFactory.createConsumer(Arrays.asList("localhost"), "testtopic", "2", "3", -1, -1,
-				null, null, null)).thenReturn(cc);
-
-	}
-
-	@After
-	public void tearDown() throws Exception {
-
-	}
-
-	@Test
-	public void testGetMatches() {
-
-		command.getMatches();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testCheckReady() {
-
-		try {
-			command.checkReady(new MRCommandContext());
-		} catch (CommandNotReadyException e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		}
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testExecute() {
-
-		String[] parts1 = { "read", "testtopic", "2", "3" };
-		String[] parts2 = { "write", "testtopic", "2", "3" };
-		List<String[]> parts = Arrays.asList(parts1, parts2);
-		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
-			String[] part = (String[]) iterator.next();
-
-			MRCommandContext context = new MRCommandContext();
-			PowerMockito.when(ToolsUtil.createBatchPublisher(context, "testtopic")).thenReturn(pub);
-			try {
-				command.execute(part, context, printStream);
-			} catch (CommandNotReadyException e) {
-				assertTrue(true);
-			}
-		}
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testExecute_error1() {
-		try {
-			PowerMockito.doThrow(new Exception()).when(cc).fetch();
-		} catch (IOException e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		} catch (Exception e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		}
-		String[] parts1 = { "read", "testtopic", "2", "3" };
-		String[] parts2 = { "write", "testtopic", "2", "3" };
-		List<String[]> parts = Arrays.asList(parts1, parts2);
-		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
-			String[] part = (String[]) iterator.next();
-
-			MRCommandContext context = new MRCommandContext();
-			PowerMockito.when(ToolsUtil.createBatchPublisher(context, "testtopic")).thenReturn(pub);
-			try {
-				command.execute(part, context, printStream);
-			} catch (CommandNotReadyException e) {
-				// TODO Auto-generated catch block
-				e.printStackTrace();
-			}
-		}
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testExecute_error2() {
-		try {
-			PowerMockito.doThrow(new IOException()).when(pub).close(500, TimeUnit.MILLISECONDS);
-			PowerMockito.doThrow(new IOException()).when(pub).send("2", "3");
-
-		} catch (IOException e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		} catch (InterruptedException e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		}
-		String[] parts1 = { "read", "testtopic", "2", "3" };
-		String[] parts2 = { "write", "testtopic", "2", "3" };
-		List<String[]> parts = Arrays.asList(parts1, parts2);
-		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
-			String[] part = (String[]) iterator.next();
-
-			MRCommandContext context = new MRCommandContext();
-			PowerMockito.when(ToolsUtil.createBatchPublisher(context, "testtopic")).thenReturn(pub);
-			try {
-				command.execute(part, context, printStream);
-			} catch (CommandNotReadyException e) {
-				// TODO Auto-generated catch block
-				e.printStackTrace();
-			}
-		}
-		assertTrue(true);
-
-	}
-
-	/*
-	 * @Test public void testExecute_error3() {
-	 * 
-	 * try { PowerMockito.doThrow(new IOException()).when(pub).send("2", "3");
-	 * PowerMockito.doThrow(new InterruptedException()).when(pub).close(500,
-	 * TimeUnit.MILLISECONDS); } catch (IOException e) { // TODO Auto-generated
-	 * catch block e.printStackTrace(); } catch (InterruptedException e) { //
-	 * TODO Auto-generated catch block e.printStackTrace(); } String[] parts1 =
-	 * { "read", "testtopic", "2", "3" }; String[] parts2 = { "write",
-	 * "testtopic", "2", "3" }; List<String[]> parts = Arrays.asList(parts1,
-	 * parts2); for (Iterator iterator = parts.iterator(); iterator.hasNext();)
-	 * { String[] part = (String[]) iterator.next(); PrintStream printStream =
-	 * new PrintStream(System.out);
-	 * 
-	 * MRCommandContext context = new MRCommandContext();
-	 * PowerMockito.when(ToolsUtil.createBatchPublisher(context,
-	 * "testtopic")).thenReturn(pub); try { command.execute(part, context,
-	 * printStream); } catch (CommandNotReadyException e) { // TODO
-	 * Auto-generated catch block e.printStackTrace(); } } assertTrue(true);
-	 * 
-	 * }
-	 */
-
-	@Test
-	public void testDisplayHelp() {
-
-		command.displayHelp(printStream);
-
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.tools;
+
+import static org.junit.Assert.assertTrue;
+
+import java.io.IOException;
+import java.io.PrintStream;
+import java.util.Arrays;
+import java.util.Iterator;
+import java.util.List;
+import java.util.concurrent.TimeUnit;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.mockito.InjectMocks;
+import org.mockito.Mock;
+import org.mockito.MockitoAnnotations;
+import org.powermock.api.mockito.PowerMockito;
+import org.powermock.core.classloader.annotations.PrepareForTest;
+import org.powermock.modules.junit4.PowerMockRunner;
+
+import com.att.nsa.cmdtool.CommandNotReadyException;
+import org.onap.dmaap.mr.client.MRBatchingPublisher;
+import org.onap.dmaap.mr.client.MRClientFactory;
+import org.onap.dmaap.mr.client.MRConsumer;
+import org.onap.dmaap.mr.client.MRTopicManager.TopicInfo;
+
+@RunWith(PowerMockRunner.class)
+@PrepareForTest({ MRClientFactory.class, ToolsUtil.class })
+public class MessageCommandTest {
+	@InjectMocks
+	private MessageCommand command;
+	@Mock
+	private MRConsumer tm;
+	@Mock
+	private TopicInfo ti;
+	@Mock
+	private MRBatchingPublisher pub;
+	@Mock
+	private MRConsumer cc;
+	@Mock
+	private PrintStream printStream;
+
+	@Before
+	public void setUp() throws Exception {
+		MockitoAnnotations.initMocks(this);
+		PowerMockito.mockStatic(MRClientFactory.class);
+		PowerMockito.mockStatic(ToolsUtil.class);
+		PowerMockito.when(MRClientFactory.createConsumer(Arrays.asList("localhost"), "testtopic", "2", "3", -1, -1,
+				null, null, null)).thenReturn(cc);
+
+	}
+
+	@After
+	public void tearDown() throws Exception {
+
+	}
+
+	@Test
+	public void testGetMatches() {
+
+		command.getMatches();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testCheckReady() {
+
+		try {
+			command.checkReady(new MRCommandContext());
+		} catch (CommandNotReadyException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testExecute() {
+
+		String[] parts1 = { "read", "testtopic", "2", "3" };
+		String[] parts2 = { "write", "testtopic", "2", "3" };
+		List<String[]> parts = Arrays.asList(parts1, parts2);
+		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
+			String[] part = (String[]) iterator.next();
+
+			MRCommandContext context = new MRCommandContext();
+			PowerMockito.when(ToolsUtil.createBatchPublisher(context, "testtopic")).thenReturn(pub);
+			try {
+				command.execute(part, context, printStream);
+			} catch (CommandNotReadyException e) {
+				assertTrue(true);
+			}
+		}
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testExecute_error1() {
+		try {
+			PowerMockito.doThrow(new Exception()).when(cc).fetch();
+		} catch (IOException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		} catch (Exception e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+		String[] parts1 = { "read", "testtopic", "2", "3" };
+		String[] parts2 = { "write", "testtopic", "2", "3" };
+		List<String[]> parts = Arrays.asList(parts1, parts2);
+		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
+			String[] part = (String[]) iterator.next();
+
+			MRCommandContext context = new MRCommandContext();
+			PowerMockito.when(ToolsUtil.createBatchPublisher(context, "testtopic")).thenReturn(pub);
+			try {
+				command.execute(part, context, printStream);
+			} catch (CommandNotReadyException e) {
+				// TODO Auto-generated catch block
+				e.printStackTrace();
+			}
+		}
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testExecute_error2() {
+		try {
+			PowerMockito.doThrow(new IOException()).when(pub).close(500, TimeUnit.MILLISECONDS);
+			PowerMockito.doThrow(new IOException()).when(pub).send("2", "3");
+
+		} catch (IOException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		} catch (InterruptedException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+		String[] parts1 = { "read", "testtopic", "2", "3" };
+		String[] parts2 = { "write", "testtopic", "2", "3" };
+		List<String[]> parts = Arrays.asList(parts1, parts2);
+		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
+			String[] part = (String[]) iterator.next();
+
+			MRCommandContext context = new MRCommandContext();
+			PowerMockito.when(ToolsUtil.createBatchPublisher(context, "testtopic")).thenReturn(pub);
+			try {
+				command.execute(part, context, printStream);
+			} catch (CommandNotReadyException e) {
+				// TODO Auto-generated catch block
+				e.printStackTrace();
+			}
+		}
+		assertTrue(true);
+
+	}
+
+	/*
+	 * @Test public void testExecute_error3() {
+	 * 
+	 * try { PowerMockito.doThrow(new IOException()).when(pub).send("2", "3");
+	 * PowerMockito.doThrow(new InterruptedException()).when(pub).close(500,
+	 * TimeUnit.MILLISECONDS); } catch (IOException e) { // TODO Auto-generated
+	 * catch block e.printStackTrace(); } catch (InterruptedException e) { //
+	 * TODO Auto-generated catch block e.printStackTrace(); } String[] parts1 =
+	 * { "read", "testtopic", "2", "3" }; String[] parts2 = { "write",
+	 * "testtopic", "2", "3" }; List<String[]> parts = Arrays.asList(parts1,
+	 * parts2); for (Iterator iterator = parts.iterator(); iterator.hasNext();)
+	 * { String[] part = (String[]) iterator.next(); PrintStream printStream =
+	 * new PrintStream(System.out);
+	 * 
+	 * MRCommandContext context = new MRCommandContext();
+	 * PowerMockito.when(ToolsUtil.createBatchPublisher(context,
+	 * "testtopic")).thenReturn(pub); try { command.execute(part, context,
+	 * printStream); } catch (CommandNotReadyException e) { // TODO
+	 * Auto-generated catch block e.printStackTrace(); } } assertTrue(true);
+	 * 
+	 * }
+	 */
+
+	@Test
+	public void testDisplayHelp() {
+
+		command.displayHelp(printStream);
+
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/dme/client/TestRunner.java b/src/test/java/org/onap/dmaap/mr/tools/TestRunner.java
similarity index 97%
copy from src/test/java/com/att/nsa/mr/dme/client/TestRunner.java
copy to src/test/java/org/onap/dmaap/mr/tools/TestRunner.java
index 08be6da..fff3bd7 100644
--- a/src/test/java/com/att/nsa/mr/dme/client/TestRunner.java
+++ b/src/test/java/org/onap/dmaap/mr/tools/TestRunner.java
@@ -1,41 +1,41 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.dme.client;
-
-import org.junit.runner.JUnitCore;
-import org.junit.runner.Result;
-import org.junit.runner.notification.Failure;
-import org.apache.log4j.Logger;
-
-public class TestRunner {
-	private static final Logger LOGGER = Logger.getLogger(TestRunner.class);
-
-	public static void main(String[] args) {
-		// TODO Auto-generated method stub
-		Result result = JUnitCore.runClasses(JUnitTestSuite.class);
-		for (Failure failure : result.getFailures()) {
-			LOGGER.info(failure.toString());
-			
-		}
-		LOGGER.info(result.wasSuccessful());
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.tools;
+
+import org.junit.runner.JUnitCore;
+import org.junit.runner.Result;
+import org.junit.runner.notification.Failure;
+import org.apache.log4j.Logger;
+
+public class TestRunner {
+	private static final Logger LOGGER = Logger.getLogger(TestRunner.class);
+
+	public static void main(String[] args) {
+		// TODO Auto-generated method stub
+		Result result = JUnitCore.runClasses(JUnitTestSuite.class);
+		for (Failure failure : result.getFailures()) {
+			LOGGER.info(failure.toString());
+			
+		}
+		LOGGER.info(result.wasSuccessful());
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/tools/ToolsUtilTest.java b/src/test/java/org/onap/dmaap/mr/tools/ToolsUtilTest.java
similarity index 95%
rename from src/test/java/com/att/nsa/mr/tools/ToolsUtilTest.java
rename to src/test/java/org/onap/dmaap/mr/tools/ToolsUtilTest.java
index 69bdd44..080d6d5 100644
--- a/src/test/java/com/att/nsa/mr/tools/ToolsUtilTest.java
+++ b/src/test/java/org/onap/dmaap/mr/tools/ToolsUtilTest.java
@@ -21,9 +21,9 @@
 /**
  * @author marcin.migdal@nokia.com
  */
-package com.att.nsa.mr.tools;
+package org.onap.dmaap.mr.tools;
 
-import com.att.nsa.mr.client.MRBatchingPublisher;
+import org.onap.dmaap.mr.client.MRBatchingPublisher;
 import java.util.Arrays;
 import java.util.List;
 import org.junit.Assert;
diff --git a/src/test/java/com/att/nsa/mr/tools/TopicCommandTest.java b/src/test/java/org/onap/dmaap/mr/tools/TopicCommandTest.java
similarity index 96%
rename from src/test/java/com/att/nsa/mr/tools/TopicCommandTest.java
rename to src/test/java/org/onap/dmaap/mr/tools/TopicCommandTest.java
index 6459e6a..e8dd073 100644
--- a/src/test/java/com/att/nsa/mr/tools/TopicCommandTest.java
+++ b/src/test/java/org/onap/dmaap/mr/tools/TopicCommandTest.java
@@ -1,224 +1,224 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.tools;
-
-import static org.junit.Assert.assertTrue;
-
-import java.io.IOException;
-import java.io.PrintStream;
-import java.util.Arrays;
-import java.util.Iterator;
-import java.util.List;
-
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.InjectMocks;
-import org.mockito.Mock;
-import org.mockito.MockitoAnnotations;
-import org.powermock.api.mockito.PowerMockito;
-import org.powermock.core.classloader.annotations.PrepareForTest;
-import org.powermock.modules.junit4.PowerMockRunner;
-
-import com.att.nsa.apiClient.http.HttpException;
-import com.att.nsa.apiClient.http.HttpObjectNotFoundException;
-import com.att.nsa.cmdtool.CommandNotReadyException;
-import com.att.nsa.mr.client.MRClientFactory;
-import com.att.nsa.mr.client.MRTopicManager.TopicInfo;
-import com.att.nsa.mr.client.MRTopicManager;
-
-@RunWith(PowerMockRunner.class)
-@PrepareForTest({ MRClientFactory.class })
-public class TopicCommandTest {
-	@InjectMocks
-	private TopicCommand command;
-	@Mock
-	private MRTopicManager tm;
-	@Mock
-	private TopicInfo ti;
-	@Mock
-	private PrintStream printStream;
-
-	@Before
-	public void setUp() throws Exception {
-
-		MockitoAnnotations.initMocks(this);
-		PowerMockito.mockStatic(MRClientFactory.class);
-		PowerMockito.when(MRClientFactory.createTopicManager(Arrays.asList("localhost"), null, null)).thenReturn(tm);
-		PowerMockito.when(tm.getTopicMetadata("testtopic")).thenReturn(ti);
-
-	}
-
-	@After
-	public void tearDown() throws Exception {
-
-	}
-
-	@Test
-	public void testGetMatches() {
-
-		command.getMatches();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testCheckReady() {
-
-		try {
-			command.checkReady(new MRCommandContext());
-		} catch (CommandNotReadyException e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		}
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testExecute() {
-
-		String[] parts1 = { "create", "testtopic", "1", "1" };
-		String[] parts2 = { "grant", "write", "read", "1" };
-		String[] parts3 = { "revoke", "write", "read", "1" };
-		String[] parts4 = { "list", "testtopic", "1", "1" };
-		List<String[]> parts = Arrays.asList(parts1, parts2, parts3, parts4);
-		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
-			String[] part = (String[]) iterator.next();
-
-			try {
-				command.execute(part, new MRCommandContext(), printStream);
-			} catch (CommandNotReadyException e) {
-				// TODO Auto-generated catch block
-				e.printStackTrace();
-			}
-			assertTrue(true);
-
-		}
-
-	}
-
-	@Test
-	public void testExecute_error() {
-
-		String[] parts1 = { "create", "testtopic", "1", "1" };
-		String[] parts2 = { "grant", "write", "read", "1" };
-		String[] parts3 = { "revoke", "write", "read", "1" };
-		String[] parts4 = { "list", "testtopic", "1", "1" };
-		List<String[]> parts = Arrays.asList(parts1, parts2, parts3, parts4);
-		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
-			String[] part = (String[]) iterator.next();
-
-			try {
-				command.execute(part, new MRCommandContext(), printStream);
-			} catch (CommandNotReadyException e) {
-				// TODO Auto-generated catch block
-				e.printStackTrace();
-			}
-			assertTrue(true);
-
-		}
-
-	}
-
-	@Test
-	public void testExecute_error_1() throws com.att.nsa.apiClient.http.HttpException, IOException {
-		PowerMockito.when(tm.getTopicMetadata("testtopic")).thenThrow(new IOException("error"));
-		PowerMockito.doThrow(new IOException()).when(tm).createTopic("testtopic", "", 1, 1);
-		PowerMockito.doThrow(new IOException()).when(tm).revokeProducer("read", "1");
-		String[] parts1 = { "create", "testtopic", "1", "1" };
-		String[] parts2 = { "grant", "read", "read", "1" };
-		String[] parts3 = { "revoke", "write", "read", "1" };
-		String[] parts4 = { "list", "testtopic", "1", "1" };
-		List<String[]> parts = Arrays.asList(parts1, parts2, parts3, parts4);
-		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
-			String[] part = (String[]) iterator.next();
-
-			try {
-				command.execute(part, new MRCommandContext(), printStream);
-			} catch (CommandNotReadyException e) {
-				// TODO Auto-generated catch block
-				e.printStackTrace();
-			}
-			assertTrue(true);
-
-		}
-
-	}
-
-	@Test
-	public void testExecute_error_2() throws com.att.nsa.apiClient.http.HttpException, IOException {
-		PowerMockito.when(tm.getTopicMetadata("testtopic")).thenThrow(new HttpObjectNotFoundException("error"));
-		PowerMockito.doThrow(new HttpException(500, "error")).when(tm).createTopic("testtopic", "", 1, 1);
-		PowerMockito.doThrow(new HttpException(500, "error")).when(tm).revokeConsumer("read", "1");
-		PowerMockito.doThrow(new HttpException(500, "error")).when(tm).allowConsumer("read", "1");
-		String[] parts1 = { "create", "testtopic", "1", "1" };
-		String[] parts2 = { "grant", "write", "write", "1" };
-		String[] parts3 = { "revoke", "read", "read", "1" };
-		String[] parts4 = { "list", "testtopic", "1", "1" };
-		List<String[]> parts = Arrays.asList(parts1, parts2, parts3, parts4);
-		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
-			String[] part = (String[]) iterator.next();
-
-			try {
-				command.execute(part, new MRCommandContext(), printStream);
-			} catch (CommandNotReadyException e) {
-				// TODO Auto-generated catch block
-				e.printStackTrace();
-			}
-			assertTrue(true);
-
-		}
-
-	}
-
-	@Test
-	public void testExecute_error_3() throws com.att.nsa.apiClient.http.HttpException, IOException {
-		PowerMockito.doThrow(new HttpException(500, "error")).when(tm).createTopic("testtopic", "", 1, 1);
-		PowerMockito.doThrow(new HttpException(500, "error")).when(tm).allowProducer("read", "1");
-		String[] parts1 = { "create", "testtopic", "1a", "1a" };
-		String[] parts2 = { "grant", "write", "read", "1" };
-		List<String[]> parts = Arrays.asList(parts1, parts2);
-		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
-			String[] part = (String[]) iterator.next();
-
-			try {
-				command.execute(part, new MRCommandContext(), printStream);
-			} catch (CommandNotReadyException e) {
-				// TODO Auto-generated catch block
-				e.printStackTrace();
-			}
-			assertTrue(true);
-
-		}
-
-	}
-
-	@Test
-	public void testDisplayHelp() {
-
-		command.displayHelp(printStream);
-		assertTrue(true);
-
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.tools;
+
+import static org.junit.Assert.assertTrue;
+
+import java.io.IOException;
+import java.io.PrintStream;
+import java.util.Arrays;
+import java.util.Iterator;
+import java.util.List;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.mockito.InjectMocks;
+import org.mockito.Mock;
+import org.mockito.MockitoAnnotations;
+import org.powermock.api.mockito.PowerMockito;
+import org.powermock.core.classloader.annotations.PrepareForTest;
+import org.powermock.modules.junit4.PowerMockRunner;
+
+import com.att.nsa.apiClient.http.HttpException;
+import com.att.nsa.apiClient.http.HttpObjectNotFoundException;
+import com.att.nsa.cmdtool.CommandNotReadyException;
+import org.onap.dmaap.mr.client.MRClientFactory;
+import org.onap.dmaap.mr.client.MRTopicManager.TopicInfo;
+import org.onap.dmaap.mr.client.MRTopicManager;
+
+@RunWith(PowerMockRunner.class)
+@PrepareForTest({ MRClientFactory.class })
+public class TopicCommandTest {
+	@InjectMocks
+	private TopicCommand command;
+	@Mock
+	private MRTopicManager tm;
+	@Mock
+	private TopicInfo ti;
+	@Mock
+	private PrintStream printStream;
+
+	@Before
+	public void setUp() throws Exception {
+
+		MockitoAnnotations.initMocks(this);
+		PowerMockito.mockStatic(MRClientFactory.class);
+		PowerMockito.when(MRClientFactory.createTopicManager(Arrays.asList("localhost"), null, null)).thenReturn(tm);
+		PowerMockito.when(tm.getTopicMetadata("testtopic")).thenReturn(ti);
+
+	}
+
+	@After
+	public void tearDown() throws Exception {
+
+	}
+
+	@Test
+	public void testGetMatches() {
+
+		command.getMatches();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testCheckReady() {
+
+		try {
+			command.checkReady(new MRCommandContext());
+		} catch (CommandNotReadyException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testExecute() {
+
+		String[] parts1 = { "create", "testtopic", "1", "1" };
+		String[] parts2 = { "grant", "write", "read", "1" };
+		String[] parts3 = { "revoke", "write", "read", "1" };
+		String[] parts4 = { "list", "testtopic", "1", "1" };
+		List<String[]> parts = Arrays.asList(parts1, parts2, parts3, parts4);
+		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
+			String[] part = (String[]) iterator.next();
+
+			try {
+				command.execute(part, new MRCommandContext(), printStream);
+			} catch (CommandNotReadyException e) {
+				// TODO Auto-generated catch block
+				e.printStackTrace();
+			}
+			assertTrue(true);
+
+		}
+
+	}
+
+	@Test
+	public void testExecute_error() {
+
+		String[] parts1 = { "create", "testtopic", "1", "1" };
+		String[] parts2 = { "grant", "write", "read", "1" };
+		String[] parts3 = { "revoke", "write", "read", "1" };
+		String[] parts4 = { "list", "testtopic", "1", "1" };
+		List<String[]> parts = Arrays.asList(parts1, parts2, parts3, parts4);
+		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
+			String[] part = (String[]) iterator.next();
+
+			try {
+				command.execute(part, new MRCommandContext(), printStream);
+			} catch (CommandNotReadyException e) {
+				// TODO Auto-generated catch block
+				e.printStackTrace();
+			}
+			assertTrue(true);
+
+		}
+
+	}
+
+	@Test
+	public void testExecute_error_1() throws com.att.nsa.apiClient.http.HttpException, IOException {
+		PowerMockito.when(tm.getTopicMetadata("testtopic")).thenThrow(new IOException("error"));
+		PowerMockito.doThrow(new IOException()).when(tm).createTopic("testtopic", "", 1, 1);
+		PowerMockito.doThrow(new IOException()).when(tm).revokeProducer("read", "1");
+		String[] parts1 = { "create", "testtopic", "1", "1" };
+		String[] parts2 = { "grant", "read", "read", "1" };
+		String[] parts3 = { "revoke", "write", "read", "1" };
+		String[] parts4 = { "list", "testtopic", "1", "1" };
+		List<String[]> parts = Arrays.asList(parts1, parts2, parts3, parts4);
+		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
+			String[] part = (String[]) iterator.next();
+
+			try {
+				command.execute(part, new MRCommandContext(), printStream);
+			} catch (CommandNotReadyException e) {
+				// TODO Auto-generated catch block
+				e.printStackTrace();
+			}
+			assertTrue(true);
+
+		}
+
+	}
+
+	@Test
+	public void testExecute_error_2() throws com.att.nsa.apiClient.http.HttpException, IOException {
+		PowerMockito.when(tm.getTopicMetadata("testtopic")).thenThrow(new HttpObjectNotFoundException("error"));
+		PowerMockito.doThrow(new HttpException(500, "error")).when(tm).createTopic("testtopic", "", 1, 1);
+		PowerMockito.doThrow(new HttpException(500, "error")).when(tm).revokeConsumer("read", "1");
+		PowerMockito.doThrow(new HttpException(500, "error")).when(tm).allowConsumer("read", "1");
+		String[] parts1 = { "create", "testtopic", "1", "1" };
+		String[] parts2 = { "grant", "write", "write", "1" };
+		String[] parts3 = { "revoke", "read", "read", "1" };
+		String[] parts4 = { "list", "testtopic", "1", "1" };
+		List<String[]> parts = Arrays.asList(parts1, parts2, parts3, parts4);
+		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
+			String[] part = (String[]) iterator.next();
+
+			try {
+				command.execute(part, new MRCommandContext(), printStream);
+			} catch (CommandNotReadyException e) {
+				// TODO Auto-generated catch block
+				e.printStackTrace();
+			}
+			assertTrue(true);
+
+		}
+
+	}
+
+	@Test
+	public void testExecute_error_3() throws com.att.nsa.apiClient.http.HttpException, IOException {
+		PowerMockito.doThrow(new HttpException(500, "error")).when(tm).createTopic("testtopic", "", 1, 1);
+		PowerMockito.doThrow(new HttpException(500, "error")).when(tm).allowProducer("read", "1");
+		String[] parts1 = { "create", "testtopic", "1a", "1a" };
+		String[] parts2 = { "grant", "write", "read", "1" };
+		List<String[]> parts = Arrays.asList(parts1, parts2);
+		for (Iterator iterator = parts.iterator(); iterator.hasNext();) {
+			String[] part = (String[]) iterator.next();
+
+			try {
+				command.execute(part, new MRCommandContext(), printStream);
+			} catch (CommandNotReadyException e) {
+				// TODO Auto-generated catch block
+				e.printStackTrace();
+			}
+			assertTrue(true);
+
+		}
+
+	}
+
+	@Test
+	public void testDisplayHelp() {
+
+		command.displayHelp(printStream);
+		assertTrue(true);
+
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/tools/TraceCommandTest.java b/src/test/java/org/onap/dmaap/mr/tools/TraceCommandTest.java
similarity index 98%
rename from src/test/java/com/att/nsa/mr/tools/TraceCommandTest.java
rename to src/test/java/org/onap/dmaap/mr/tools/TraceCommandTest.java
index 6ac106a..de76acd 100644
--- a/src/test/java/com/att/nsa/mr/tools/TraceCommandTest.java
+++ b/src/test/java/org/onap/dmaap/mr/tools/TraceCommandTest.java
@@ -1,102 +1,102 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP Policy Engine
- * ================================================================================
- * 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=========================================================
- */
-
-package com.att.nsa.mr.tools;
-
-import static org.junit.Assert.assertTrue;
-
-import java.io.PrintStream;
-
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.InjectMocks;
-import org.mockito.Mock;
-import org.mockito.MockitoAnnotations;
-import org.powermock.modules.junit4.PowerMockRunner;
-
-import com.att.nsa.cmdtool.CommandNotReadyException;
-
-@RunWith(PowerMockRunner.class)
-public class TraceCommandTest {
-	@InjectMocks
-	private TraceCommand command;
-	private String[] parts = new String[5];
-	@Mock
-	private PrintStream printStream;
-
-	@Before
-	public void setUp() throws Exception {
-		MockitoAnnotations.initMocks(this);
-		for (int i = 0; i < parts.length; i++) {
-			parts[i] = "String" + (i + 1);
-		}
-
-	}
-
-	@After
-	public void tearDown() throws Exception {
-
-	}
-
-	@Test
-	public void testGetMatches() {
-
-		command.getMatches();
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testCheckReady() {
-
-		try {
-			command.checkReady(new MRCommandContext());
-		} catch (CommandNotReadyException e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		}
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testExecute() {
-
-		try {
-			command.execute(parts, new MRCommandContext(), printStream);
-		} catch (CommandNotReadyException e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		}
-		assertTrue(true);
-
-	}
-
-	@Test
-	public void testDisplayHelp() {
-
-		command.displayHelp(printStream);
-		assertTrue(true);
-
-	}
-
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP Policy Engine
+ * ================================================================================
+ * 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=========================================================
+ */
+
+package org.onap.dmaap.mr.tools;
+
+import static org.junit.Assert.assertTrue;
+
+import java.io.PrintStream;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.mockito.InjectMocks;
+import org.mockito.Mock;
+import org.mockito.MockitoAnnotations;
+import org.powermock.modules.junit4.PowerMockRunner;
+
+import com.att.nsa.cmdtool.CommandNotReadyException;
+
+@RunWith(PowerMockRunner.class)
+public class TraceCommandTest {
+	@InjectMocks
+	private TraceCommand command;
+	private String[] parts = new String[5];
+	@Mock
+	private PrintStream printStream;
+
+	@Before
+	public void setUp() throws Exception {
+		MockitoAnnotations.initMocks(this);
+		for (int i = 0; i < parts.length; i++) {
+			parts[i] = "String" + (i + 1);
+		}
+
+	}
+
+	@After
+	public void tearDown() throws Exception {
+
+	}
+
+	@Test
+	public void testGetMatches() {
+
+		command.getMatches();
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testCheckReady() {
+
+		try {
+			command.checkReady(new MRCommandContext());
+		} catch (CommandNotReadyException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testExecute() {
+
+		try {
+			command.execute(parts, new MRCommandContext(), printStream);
+		} catch (CommandNotReadyException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+		assertTrue(true);
+
+	}
+
+	@Test
+	public void testDisplayHelp() {
+
+		command.displayHelp(printStream);
+		assertTrue(true);
+
+	}
+
+}
diff --git a/src/test/java/com/att/nsa/mr/tools/ValidatorUtilTest.java b/src/test/java/org/onap/dmaap/mr/tools/ValidatorUtilTest.java
similarity index 98%
rename from src/test/java/com/att/nsa/mr/tools/ValidatorUtilTest.java
rename to src/test/java/org/onap/dmaap/mr/tools/ValidatorUtilTest.java
index ec382f4..1306a30 100644
--- a/src/test/java/com/att/nsa/mr/tools/ValidatorUtilTest.java
+++ b/src/test/java/org/onap/dmaap/mr/tools/ValidatorUtilTest.java
@@ -20,7 +20,7 @@
  *  
  *******************************************************************************/
 
-package com.att.nsa.mr.tools;
+package org.onap.dmaap.mr.tools;
 
 import static org.junit.Assert.assertEquals;
 
@@ -28,7 +28,7 @@
 
 import org.junit.Test;
 
-import com.att.nsa.mr.test.clients.ProtocolTypeConstants;
+import org.onap.dmaap.mr.test.clients.ProtocolTypeConstants;
 
 public class ValidatorUtilTest {
 
diff --git a/version.properties b/version.properties
index c31717c..ad77b29 100644
--- a/version.properties
+++ b/version.properties
@@ -27,7 +27,7 @@
 
 major=1
 minor=1
-patch=8
+patch=9
 
 base_version=${major}.${minor}.${patch}
 
