diff --git a/extensions-core/s3-extensions/src/test/java/org/apache/druid/storage/s3/S3DataSegmentPusherConfigTest.java b/extensions-core/s3-extensions/src/test/java/org/apache/druid/storage/s3/S3DataSegmentPusherConfigTest.java index c35733618a7..bf5f07efb93 100644 --- a/extensions-core/s3-extensions/src/test/java/org/apache/druid/storage/s3/S3DataSegmentPusherConfigTest.java +++ b/extensions-core/s3-extensions/src/test/java/org/apache/druid/storage/s3/S3DataSegmentPusherConfigTest.java @@ -29,6 +29,7 @@ import javax.validation.ConstraintViolation; import javax.validation.Validation; import javax.validation.Validator; import java.io.IOException; +import java.util.Map; import java.util.Set; public class S3DataSegmentPusherConfigTest @@ -51,9 +52,10 @@ public class S3DataSegmentPusherConfigTest String jsonConfig = "{\"bucket\":\"bucket1\",\"baseKey\":\"dataSource1\"}"; String expectedJsonConfig = "{\"bucket\":\"bucket1\",\"baseKey\":\"dataSource1\"," + "\"disableAcl\":false,\"maxListingLength\":1024,\"useS3aSchema\":false}"; - S3DataSegmentPusherConfig config = JSON_MAPPER.readValue(jsonConfig, S3DataSegmentPusherConfig.class); - Assert.assertEquals(expectedJsonConfig, JSON_MAPPER.writeValueAsString(config)); + Map expected = JSON_MAPPER.readValue(expectedJsonConfig, Map.class); + Map actual = JSON_MAPPER.readValue(JSON_MAPPER.writeValueAsString(config), Map.class); + Assert.assertEquals(expected, actual); } @Test