GenericImpl implements Generic { @Override public Generic setLowerBound(String lowerBound) { this.lowerBound = lowerBound; return this; } GenericImpl();  GenericImpl(String lowerBound);  GenericImpl(Type... upperBounds);  GenericImpl(String lowerBound, Type... upperBounds); protected  GenericImpl(Generic prototype); @Override Generic setLowerBound(String lowerBound); @Override Optional<String> getLowerBound(); @Override Generic setBoundType(BoundType type); @Override BoundType getBoundType(); @Override List<Type> getUpperBounds(); @Override Type asType(); @Override GenericImpl copy(); @Override int hashCode(); @Override boolean equals(Object obj);  }
@Test void setLowerBound() { final String low = "A"; instance().setLowerBound(low); assertEquals(low, instance().getLowerBound().orElseThrow(NoSuchElementException::new)); }
@Test void asTypeWildcard() { instance().setLowerBound("?"); assertThrows(UnsupportedOperationException.class, instance()::asType); }