-
-
Notifications
You must be signed in to change notification settings - Fork 766
Closed
Closed
Copy link
Labels
language: KotlinAn issue related to using AssertJ with KotlinAn issue related to using AssertJ with Kotlin
Milestone
Description
Describe the bug
The change made in #3673 (I think) causes a compilation problem with Kotlin due to ambiguous overloading of extracting on ObjectAssert. The failure is as follows:
> Task :spring-boot-project:spring-boot-docs:compileKotlin
e: file:///Users/awilkinson/dev/spring-projects/spring-boot/main/spring-boot-project/spring-boot-docs/src/main/kotlin/org/springframework/boot/docs/testing/springbootapplications/autoconfiguredwebservices/client/MyWebServiceClientTests.kt:36:42 Overload resolution ambiguity:
public open fun <T : Any!> extracting(extractor: Function<in Response!, TypeVariable(T)!>!): AbstractObjectAssert<*, TypeVariable(T)!>! defined in org.assertj.core.api.ObjectAssert
public final fun <T : Any!> extracting(vararg extractors: Function<in Response!, out TypeVariable(T)!>!): AbstractListAssert<*, (MutableList<out TypeVariable(T)!>..List<TypeVariable(T)!>?), TypeVariable(T)!, ObjectAssert<TypeVariable(T)!>!>! defined in org.assertj.core.api.ObjectAssert
- assertj core version: 3.27.2
- java version: 17 (but it's not Java-version-specific)
- test framework version: N/A
- os (if relevant): N/A
Test case reproducing the bug
I can provide some Kotlin source that fails to compile if needed. You can already see an example here.
Metadata
Metadata
Assignees
Labels
language: KotlinAn issue related to using AssertJ with KotlinAn issue related to using AssertJ with Kotlin