Unnamed @Given fields in a POJO rule that are a collection type try to collect any unnamed facts of compatible types and add them to the collection. But if the field is genericized to a wildcard type (like Set<? extends Number>), it was hitting a ClassCastException attempting to hard-cast the parameter to Class<?> rather than WildCardType or TypeVariable as appropriate. This will now identify eligible wildcard types for those wildcarded collections as well.
Unnamed
@Given
fields in a POJO rule that are a collection type try to collect any unnamed facts of compatible types and add them to the collection. But if the field is genericized to a wildcard type (likeSet<? extends Number>
), it was hitting a ClassCastException attempting to hard-cast the parameter toClass<?>
rather thanWildCardType
orTypeVariable
as appropriate. This will now identify eligible wildcard types for those wildcarded collections as well.