pap - sonar issue fix

replace by assertNotSame

Issue-ID: POLICY-2616
Change-Id: I927dbd8c57654cd2d2ef6262d13d63c79ba9035f
Signed-off-by: Taka Cho <takamune.cho@att.com>
diff --git a/main/src/test/java/org/onap/policy/pap/main/comm/msgdata/RequestImplTest.java b/main/src/test/java/org/onap/policy/pap/main/comm/msgdata/RequestImplTest.java
index 414c1db..d57f667 100644
--- a/main/src/test/java/org/onap/policy/pap/main/comm/msgdata/RequestImplTest.java
+++ b/main/src/test/java/org/onap/policy/pap/main/comm/msgdata/RequestImplTest.java
@@ -27,6 +27,7 @@
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertFalse;
 import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertNotSame;
 import static org.junit.Assert.assertNull;
 import static org.junit.Assert.assertSame;
 import static org.junit.Assert.assertTrue;
@@ -219,7 +220,7 @@
         req.startPublishing();
         QueueToken<PdpMessage> token2 = queue.poll();
         assertNotNull(token2);
-        assertTrue(token2 != token);
+        assertNotSame(token, token2);
         assertSame(msg, token2.get());
     }
 
@@ -247,7 +248,7 @@
 
         // a new token should have been placed in the queue
         QueueToken<PdpMessage> token2 = queue.poll();
-        assertTrue(token != token2);
+        assertNotSame(token, token2);
         assertNull(queue.poll());
         assertNotNull(token2);
         assertSame(msg3, token2.get());
@@ -259,7 +260,7 @@
 
         // a new token should have been placed in the queue
         QueueToken<PdpMessage> token3 = queue.poll();
-        assertTrue(token2 != token3);
+        assertNotSame(token2, token3);
         assertNull(queue.poll());
         assertNotNull(token3);
         assertSame(msg4, token3.get());
diff --git a/main/src/test/java/org/onap/policy/pap/main/notification/PolicyCommonTrackerTest.java b/main/src/test/java/org/onap/policy/pap/main/notification/PolicyCommonTrackerTest.java
index fc43c7a..34d4db6 100644
--- a/main/src/test/java/org/onap/policy/pap/main/notification/PolicyCommonTrackerTest.java
+++ b/main/src/test/java/org/onap/policy/pap/main/notification/PolicyCommonTrackerTest.java
@@ -23,6 +23,7 @@
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertFalse;
 import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertNotSame;
 import static org.junit.Assert.assertSame;
 import static org.junit.Assert.assertTrue;
 
@@ -126,7 +127,7 @@
         assertFalse(data.isComplete());
 
         // policy 2 should have its own data
-        assertTrue(map.get(policy2) != data);
+        assertNotSame(data, map.get(policy2));
         data = map.get(policy2);
         assertNotNull(data);
         assertFalse(data.isComplete());