From ece57725d49bb77968024468a1365906b5046a8e Mon Sep 17 00:00:00 2001 From: TrueJacobG Date: Sat, 8 Mar 2025 15:20:39 +0100 Subject: [PATCH] fix list type in 2.5.13, people list is not used, doctors list needs to have type List, because of the type checking --- .../asciidoc/user-guide/assertj-core-assertions-guide.adoc | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/docs/asciidoc/user-guide/assertj-core-assertions-guide.adoc b/src/docs/asciidoc/user-guide/assertj-core-assertions-guide.adoc index 9994a951..3bb16399 100644 --- a/src/docs/asciidoc/user-guide/assertj-core-assertions-guide.adoc +++ b/src/docs/asciidoc/user-guide/assertj-core-assertions-guide.adoc @@ -2152,8 +2152,7 @@ Person leonard = new Person("Leonard Hofstadter", false); Person raj = new Person("Raj Koothrappali", false); Person howard = new Person("Howard Wolowitz", false); -List doctors = list(drSheldon, drLeonard, drRaj); -List people = list(sheldon, leonard, raj); +List doctors = list(drSheldon, drLeonard, drRaj); RecursiveComparisonConfiguration configuration = RecursiveComparisonConfiguration.builder() .withIgnoredFields("hasPhd") @@ -2169,7 +2168,6 @@ assertThat(doctors).usingRecursiveFieldByFieldElementComparator(configuration) .contains(leonard); // assertion fails because howard is missing and leonard is not expected. -people = list(howard, sheldon, raj) assertThat(doctors).usingRecursiveFieldByFieldElementComparator(configuration) .contains(howard); ----