### Question:
ClassDeployment implements Deployment { @Override public int hashCode() { int result = consumers.hashCode(); result = 31 * result + services.hashCode(); result = 31 * result + coreServices.hashCode(); return result; } ClassDeployment(Class<?> ...deploymentClasses); @Override Set<Class<?>> getCoreServices(); @Override Set<Class<?>> getServices(); @Override Set<Class<?>> getConsumers(); @Override ClassLoader getClassLoader(); @Override boolean equals(Object o); @Override int hashCode();  }### Answer:
@Test public void hashCodeEqualsTest(){ ClassDeployment d1 = new ClassDeployment(TestCoreService1.class, TestQueue1.class, TestQueue2.class, TestService1.class, TestTopic1.class); ClassDeployment d2 = new ClassDeployment(TestCoreService1.class, TestQueue1.class, TestQueue2.class, TestService1.class, TestTopic1.class); assertEquals(d1.hashCode(), d2.hashCode()); }
@Test public void hashCodeNotEqualsTest(){ ClassDeployment d1 = new ClassDeployment(TestCoreService1.class, TestQueue1.class, TestQueue2.class, TestService1.class, TestTopic1.class); ClassDeployment d2 = new ClassDeployment(TestCoreService1.class, TestQueue2.class, TestService1.class, TestTopic1.class); assertNotEquals(d1.hashCode(), d2.hashCode()); }