### Question:
Reflect { public static boolean isCollection(Class<?> fieldClass) { return Collection.class.isAssignableFrom(fieldClass); } Reflect(Class parametrizedClass); static boolean isCollection(Class<?> fieldClass); static boolean isCollection(Object object); static List<Field> getAllFields(Class<?> fieldClass); static boolean isAnnotationPresent(Class<?> fieldClass, String fieldName, Class<? extends Annotation> annotation); @SuppressWarnings("unchecked") boolean isSuperClass(Class subClass); boolean isSuperClass(Type t); boolean isSuperClass(Object object); @SuppressWarnings("unchecked") boolean isCollectionField(Field field); List<Field> getInheritedFields(Class<?> subClass); boolean hasField(Field field);  }### Answer:
@Test public void isCollection_shouldReturnTrueIfGivenFieldClassIsCollectionClass() { Assert.assertTrue(Reflect.isCollection(ArrayList.class)); }
@Test public void isCollection_shouldReturnFalseIfGivenObjectIsNotACollection() { Assert.assertFalse(Reflect.isCollection(new NormalClass())); }
@Test public void isCollection_shouldReturnTrueIfGivenObjectIsCollectionClass() { Assert.assertTrue(Reflect.isCollection(new ArrayList<>())); }
@Test public void isCollectionField_shouldReturnFalseIfGivenFieldIsNotACollection() { Assert.assertFalse(Reflect.isCollection(NormalClass.class)); }