Fix issues found by FindBugs: URF_UNREAD_PUBLIC_OR_PROTECTED_FIELD
http://findbugs.sourceforge.net/bugDescriptions.html#URF_UNREAD_PUBLIC_OR_PROTECTED_FIELD
Note: the fix for IntentMap.changedEvent is actually a workaround - adding
toString() method that refers to the "unread public or protected fields").
The "eventType" and "intent" fields might be used in the future.
Change-Id: I165183fcbefd3db0d01a728f14cbd6b7681a2f3a
diff --git a/src/test/java/net/onrc/onos/apps/bgproute/PtreeTest.java b/src/test/java/net/onrc/onos/apps/bgproute/PtreeTest.java
index f0fd40a..1b4b8b1 100644
--- a/src/test/java/net/onrc/onos/apps/bgproute/PtreeTest.java
+++ b/src/test/java/net/onrc/onos/apps/bgproute/PtreeTest.java
@@ -53,7 +53,7 @@
byteAddresses.put(prefix, InetAddresses.forString(address).getAddress());
PtreeNode node = ptree.acquire(byteAddresses.get(prefix), prefixLength);
- node.rib = new RibEntry("192.168.10.101", "192.168.60.1");
+ // node.rib = new RibEntry("192.168.10.101", "192.168.60.1");
ooptrie.put(new Prefix(byteAddresses.get(prefix), prefixLength),
new RibEntry("192.168.10.101", "192.168.60.1"));
}
@@ -75,14 +75,16 @@
//First let's test an empty Ptree
Ptree localPtree = new Ptree(32);
PtreeNode node = localPtree.acquire(new byte[]{0x00, 0x00, 0x00, 0x00});
- assertTrue(node != null && node.rib == null);
+ // assertTrue(node != null && node.rib == null);
+ assertTrue(node != null);
//Now let's look at the prepopulated tree
String testPrefix = "206.17.144.0/20";
PtreeNode existingNode = ptree.acquire(byteAddresses.get(testPrefix), 20);
printByteArray(existingNode.key);
printByteArray(byteAddresses.get(testPrefix));
- assertTrue(existingNode != null && existingNode.rib == null);
+ // assertTrue(existingNode != null && existingNode.rib == null);
+ assertTrue(existingNode != null);
assertTrue(Arrays.equals(existingNode.key, byteAddresses.get(testPrefix)));
}