import static org.junit.Assert.assertFalse;
import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertThat;
-
import java.util.Arrays;
import java.util.Collection;
import java.util.List;
is(true));
assertThat(peerTO.getFullyQualifiedName(), is(PACKAGE_NAME
+ ".Peer"));
- assertThat(peerTO.getMethods().size(), is(5));
- Method getPort = findFirstMethodByName(peerTO.getMethods(),
- "getPort");
+ assertThat(peerTO.getMethods().size(), is(5 + 2/*hashCode Equals*/));
+
+ Method getPort = findFirstMethodByName(peerTO.getMethods(), "getPort");
assertNotNull(getPort);
Method setPort = findFirstMethodByName(peerTO.getMethods(),
"setPort");
}
}
- private Method findFirstMethodByName(List<? extends Method> methods,
- String name) {
+ private static Method findFirstMethodByName(final List<? extends Method> methods, final String name) {
for (Method ms : methods) {
if (name.equals(ms.getName())) {
return ms;