rdblue commented on code in PR #11811: URL: https://github.com/apache/iceberg/pull/11811#discussion_r1890507433
########## data/src/test/java/org/apache/iceberg/data/DataTestHelpers.java: ########## @@ -36,7 +36,10 @@ public static void assertEquals(Types.StructType struct, Record expected, Record assertEquals( field.type(), expected.getField(expectedField.name()), actual.getField(field.name())); } else { - assertThat(actual.getField(field.name())).isEqualTo(field.initialDefault()); + assertEquals( + field.type(), + GenericDataUtil.internalToGeneric(field.type(), field.initialDefault()), + actual.getField(field.name())); Review Comment: This was the test bug. Rather than asserting that the value was passed back unchanged, it should have delegated to `assertEquals` that checks the representation of the value. The expected value (default) also needs to be converted to generic because the generic data model tests use the generic data model as the source representation. -- 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