### Question:
JexlNodeSet implements Set<JexlNode> { @Override public boolean equals(Object o) { if (o == null) return false; if (this == o) return true; if (o instanceof JexlNodeSet) { JexlNodeSet other = (JexlNodeSet) o; if (this.size() != other.size()) return false; return this.nodeMap.keySet().equals(other.nodeMap.keySet()); } return false; } JexlNodeSet();  JexlNodeSet(boolean useSourceNodeForKeys); Collection<JexlNode> getNodes(); Set<String> getNodeKeys(); @Override int size(); @Override boolean isEmpty(); @Override boolean contains(Object o); @Override Iterator<JexlNode> iterator(); @Override Object[] toArray(); @Override T[] toArray(T[] ts); @Override boolean add(JexlNode node); @Override boolean remove(Object o); @Override boolean containsAll(Collection<?> collection); @Override boolean addAll(Collection<? extends JexlNode> collection); @Override boolean retainAll(Collection<?> collection); @Override boolean removeAll(Collection<?> collection); @Override void clear(); String buildKey(JexlNode node); @Override boolean equals(Object o); @Override int hashCode();  }### Answer:
@Test public void testEquals() { JexlNodeSet prime = new JexlNodeSet(); assertFalse(prime.equals(null)); assertTrue(prime.equals(prime)); JexlNodeSet other = new JexlNodeSet(); other.add(JexlNodeFactory.buildEQNode("FOO", "bar")); assertFalse(prime.equals(other)); prime.add(JexlNodeFactory.buildEQNode("FOO", "bar")); assertTrue(prime.equals(other)); }