nk1506 commented on code in PR #9927: URL: https://github.com/apache/iceberg/pull/9927#discussion_r1523122080
########## core/src/test/java/org/apache/iceberg/TestMetadataUpdateParser.java: ########## @@ -1036,43 +1038,39 @@ public void assertEquals( private static void assertEqualsAssignUUID( MetadataUpdate.AssignUUID expected, MetadataUpdate.AssignUUID actual) { - Assert.assertEquals("UUIDs should be equal", expected.uuid(), actual.uuid()); + assertThat(actual.uuid()).isEqualTo(expected.uuid()); } private static void assertEqualsUpgradeFormatVersion( MetadataUpdate.UpgradeFormatVersion expected, MetadataUpdate.UpgradeFormatVersion actual) { - Assert.assertEquals( - "Format version should be equal", expected.formatVersion(), actual.formatVersion()); + assertThat(actual.formatVersion()).isEqualTo(expected.formatVersion()); } private static void assertEqualsAddSchema( MetadataUpdate.AddSchema expected, MetadataUpdate.AddSchema actual) { - Assert.assertTrue("Schemas should be the same", expected.schema().sameSchema(actual.schema())); - Assert.assertEquals( - "Last column id should be equal", expected.lastColumnId(), actual.lastColumnId()); + assertThat(actual.schema().sameSchema(expected.schema())).isTrue(); + assertThat(actual.lastColumnId()).isEqualTo(expected.lastColumnId()); } private static void assertEqualsSetCurrentSchema( MetadataUpdate.SetCurrentSchema expected, MetadataUpdate.SetCurrentSchema actual) { - Assert.assertEquals("Schema id should be equal", expected.schemaId(), actual.schemaId()); + assertThat(actual.schemaId()).isEqualTo(expected.schemaId()); } private static void assertEqualsSetDefaultPartitionSpec( MetadataUpdate.SetDefaultPartitionSpec expected, MetadataUpdate.SetDefaultPartitionSpec actual) { - Assertions.assertThat(actual.specId()).isEqualTo(expected.specId()); + assertThat(actual.specId()).isEqualTo(expected.specId()); } private static void assertEqualsAddPartitionSpec( MetadataUpdate.AddPartitionSpec expected, MetadataUpdate.AddPartitionSpec actual) { - Assert.assertEquals( - "Unbound partition specs should have the same spec id", - expected.spec().specId(), - actual.spec().specId()); - Assert.assertEquals( - "Unbound partition specs should have the same number of fields", - expected.spec().fields().size(), - actual.spec().fields().size()); + assertThat(actual.spec().specId()) + .as("Unbound partition specs should have the same spec id") + .isEqualTo(expected.spec().specId()); + assertThat(expected.spec().fields()) Review Comment: ```suggestion assertThat(expected.spec().fields()) assertThat(actual.spec().fields()) ``` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@iceberg.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@iceberg.apache.org For additional commands, e-mail: issues-h...@iceberg.apache.org