-
-
Notifications
You must be signed in to change notification settings - Fork 772
Description
Discussed in https://github.com/orgs/assertj/discussions/3994
Originally posted by erizzo October 30, 2025
I just cloned the repo and imported into Eclipse, set the project to use Java 25.
There are compilation errors in 2 classes, AbstractObjectAssert and AbstractIterableAssert, all centered around typing errors.
In AbstractObjectAssert the same error shows up on 4 different lines. Here's one example, line 467
public AbstractObjectAssert<?, ?> extracting(String propertyOrField) {
return super.extracting(propertyOrField, this::newObjectAssert);
}The type of newObjectAssert(Object) from the type AbstractObjectAssert<SELF,ACTUAL> is AbstractObjectAssert<?,Object>, this is incompatible with the descriptor's return type: AbstractObjectAssert<AbstractObjectAssert<AbstractObjectAssert<?,Object>,Object>,Object>
In AbstractIterableAssert, there are 2 instances of a different error. One example, line 3011:
private ELEMENT lastElement() {
if (actual instanceof List<? extends ELEMENT> list) {
return list.get(list.size() - 1);
}Type ACTUAL cannot be safely cast to List<? extends ELEMENT>
Only the AbstractIterableAssert errors show up in IntelliJ.
Has anyone else run into these compilation errors?