ajantha-bhat commented on code in PR #11919:
URL: https://github.com/apache/iceberg/pull/11919#discussion_r1908005218
##########
core/src/test/java/org/apache/iceberg/avro/AvroTestHelpers.java:
##########
@@ -126,9 +139,18 @@ private static void assertEquals(Type type, Object
expected, Object actual) {
assertThat(actual).as("Primitive value should be equal to
expected").isEqualTo(expected);
break;
case STRUCT:
- assertThat(expected).as("Expected should be a
Record").isInstanceOf(Record.class);
- assertThat(actual).as("Actual should be a
Record").isInstanceOf(Record.class);
- assertEquals(type.asStructType(), (Record) expected, (Record) actual);
+ assertThat(expected)
Review Comment:
This is tricky. The maps and lists also can have internal members as struct
(recursive calls). So, I didn't use boolean flag here as non-private methods
also need to pass the boolean.
But I can understand the concern about mixed types in struct. I have added a
`InternalTestHelper` now with code duplication. It can be used for parquet
internal test also.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]