From 8641766d5df3087e4bdc0d06ecf17bce58a5c62c Mon Sep 17 00:00:00 2001 From: Yevhenii Viktorov Date: Mon, 25 Oct 2021 17:41:14 +0300 Subject: [PATCH] Refactor 2 assertions in one in ExchangeServiceTest --- .../org/prebid/server/auction/ExchangeServiceTest.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/test/java/org/prebid/server/auction/ExchangeServiceTest.java b/src/test/java/org/prebid/server/auction/ExchangeServiceTest.java index 8b505689df8..3351744cc3b 100644 --- a/src/test/java/org/prebid/server/auction/ExchangeServiceTest.java +++ b/src/test/java/org/prebid/server/auction/ExchangeServiceTest.java @@ -666,8 +666,8 @@ public void shouldPassRequestWithExtPrebidToDefinedBidder() { final ExtRequestPrebid prebid1 = capturedBidRequest1.getBidRequest().getExt().getPrebid(); assertThat(prebid1).isNotNull(); final JsonNode bidders1 = prebid1.getBidders(); - assertThat(bidders1).isNotNull(); - assertThat(bidders1.fields()).toIterable() + assertThat(bidders1).isNotNull() + .extracting(JsonNode::fields).asList() .containsOnly(entry("bidder", mapper.createObjectNode().put("test1", "test1"))); final ArgumentCaptor bidRequest2Captor = ArgumentCaptor.forClass(BidderRequest.class); @@ -676,8 +676,8 @@ public void shouldPassRequestWithExtPrebidToDefinedBidder() { final ExtRequestPrebid prebid2 = capturedBidRequest2.getExt().getPrebid(); assertThat(prebid2).isNotNull(); final JsonNode bidders2 = prebid2.getBidders(); - assertThat(bidders2).isNotNull(); - assertThat(bidders2.fields()).toIterable() + assertThat(bidders2).isNotNull() + .extracting(JsonNode::fields).asList() .containsOnly(entry("bidder", mapper.createObjectNode().put("test2", "test2"))); }