### Question:
Types { public static GenericArrayType genericArrayType(Type componentType) { return new DefaultGenericArrayType(componentType); } private  Types(); static TypeVariable<D> typeVariable(D declaration, String name,
		Type... bounds); static GenericArrayType genericArrayType(Type componentType); static ParameterizedType parameterizedType(Class<?> rawType, Type... actualTypeArguments); static WildcardType unboundedWildcardType(); static WildcardType upperBoundedWildcardType(Type upperBound); static WildcardType lowerBoundedWildcardType(Type lowerBound); static Type valueOf(String typeName); static Type valueOf(String typeName, Set<String> imports);  }### Answer:
@Test public void genericArrayType() { GenericArrayType type = Types.genericArrayType(Integer.class); assertNotNull(type); assertEquals(Integer.class, type.getGenericComponentType()); }
@Test(expected = NullPointerException.class) public void genericArrayTypeWithNull() { try { Types.genericArrayType(null); } catch (NullPointerException exception) { assertEquals("componentType cannot be null", exception.getMessage()); throw exception; } }