VariableEntry implements Serializable, Comparable<VariableEntry> { @Override public boolean equals(Object arg) { if (arg == null || !(arg instanceof VariableEntry)) { return false; } VariableEntry o = (VariableEntry) arg; return new EqualsBuilder().append(key, o.key).append(value, o.value).isEquals(); } VariableEntry();  VariableEntry(String key, String value); void setKey(String key); void setValue(String value); String getKey(); String getValue(); @Override int hashCode(); @Override boolean equals(Object arg); @Override String toString(); @Override int compareTo(VariableEntry o);  }
@Test public void testEquals_1() throws Exception { VariableEntry fixture = new VariableEntry("", ""); Object arg = null; boolean result = fixture.equals(arg); assertTrue(!result); }
@Test public void testEquals_2() throws Exception { VariableEntry fixture = new VariableEntry("", ""); Object arg = new Object(); boolean result = fixture.equals(arg); assertTrue(!result); }
@Test public void testEquals_3() throws Exception { VariableEntry fixture = new VariableEntry("", ""); Object arg = new VariableEntry("", ""); boolean result = fixture.equals(arg); assertTrue(result); }
@Test public void testEquals_4() throws Exception { VariableEntry fixture = new VariableEntry("", ""); Object arg = new VariableEntry("", ""); boolean result = fixture.equals(arg); assertTrue(result); }