From 539bf3438d04852f5670c8495e7f4d9fe8e201fa Mon Sep 17 00:00:00 2001 From: anuragkumawat Date: Fri, 19 May 2023 08:48:58 +0530 Subject: [PATCH] Java 20277 (#14046) * JAVA-20277 GitHub Issue: Regarding article Introduction to JsonPath * JAVA-20277 Code Review Changes --- .../jsonpath/introduction/ServiceIntegrationTest.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/json-modules/json-path/src/test/java/com/baeldung/jsonpath/introduction/ServiceIntegrationTest.java b/json-modules/json-path/src/test/java/com/baeldung/jsonpath/introduction/ServiceIntegrationTest.java index 1a84fae3c4..a64495c0f8 100644 --- a/json-modules/json-path/src/test/java/com/baeldung/jsonpath/introduction/ServiceIntegrationTest.java +++ b/json-modules/json-path/src/test/java/com/baeldung/jsonpath/introduction/ServiceIntegrationTest.java @@ -103,11 +103,11 @@ public class ServiceIntegrationTest { @Test public void givenJsonPathWithFilterPredicate_whenReadingRootNode_thenCorrect() { - Filter expensiveFilter = Filter.filter(Criteria.where("director") + Filter directorSamMendesFilter = Filter.filter(Criteria.where("director") .contains("Sam Mendes")); - List> predicate = JsonPath.parse(jsonString) - .read("$[?]['director']", expensiveFilter); - assertEquals(predicate.size(), 2); + List> samMendesMovies = JsonPath.parse(jsonString) + .read("$[?]['director']", directorSamMendesFilter); + assertEquals(samMendesMovies.size(), 2); } } \ No newline at end of file