From 0e879640efa08801a8f66105b28827ec99e07146 Mon Sep 17 00:00:00 2001 From: Simon Verhoeven Date: Sun, 9 Jul 2023 12:46:02 +0200 Subject: [PATCH] GH-236 - Code fixes in Introducing Spring Modulith document. Replaced the deprecated matchingMapped with matching, and adapted the way the orderId is read from the event. --- etc/introducing-spring-modulith.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/etc/introducing-spring-modulith.adoc b/etc/introducing-spring-modulith.adoc index ad8a5372c..d5d3a99d4 100644 --- a/etc/introducing-spring-modulith.adoc +++ b/etc/introducing-spring-modulith.adoc @@ -144,7 +144,7 @@ class OrderIntegrationTests { // Find all OrderCompleted events referring to our reference order var matchingMapped = events.ofType(OrderCompleted.class) - .matchingMapped(OrderCompleted::getOrderId, reference.getId()::equals); + .matching(OrderCompleted::orderId, reference.getId()); assertThat(matchingMapped).hasSize(1); }