voonhous commented on code in PR #17763:
URL: https://github.com/apache/hudi/pull/17763#discussion_r2656148867


##########
hudi-hadoop-common/src/test/java/org/apache/parquet/avro/TestAvroSchemaConverter.java:
##########
@@ -819,33 +832,34 @@ public void testReuseNameInNestedStructureAtSameLevel() 
throws Exception {
 
   @Test
   public void testUUIDType() throws Exception {
-    Schema fromAvro = Schema.createRecord(
+    HoodieSchema fromSchema = HoodieSchema.createRecord(
         "myrecord",
         null,
         null,
         false,
-        Arrays.asList(
-            new Schema.Field("uuid", 
LogicalTypes.uuid().addToSchema(Schema.create(STRING)), null, null)));
+        Collections.singletonList(
+            HoodieSchemaField.of("uuid", HoodieSchema.createUUID(), null, 
null)));
     String parquet = "message myrecord {\n" + "  required binary uuid 
(STRING);\n" + "}\n";
-    Schema toAvro = Schema.createRecord(
+    HoodieSchema toSchema = HoodieSchema.createRecord(
         "myrecord",
         null,
         null,
         false,
-        Arrays.asList(new Schema.Field("uuid", Schema.create(STRING), null, 
null)));
+        Collections.singletonList(HoodieSchemaField.of("uuid", 
HoodieSchema.create(HoodieSchemaType.STRING), null, null)));
 
-    testAvroToParquetConversion(fromAvro, parquet);
-    testParquetToAvroConversion(toAvro, parquet);
+    testAvroToParquetConversion(fromSchema, parquet);
+    testParquetToAvroConversion(toSchema, parquet);
 
     assertEquals(
-        COMPATIBLE, checkReaderWriterCompatibility(fromAvro, 
toAvro).getType());
+        COMPATIBLE, checkReaderWriterCompatibility(fromSchema.toAvroSchema(), 
toSchema.toAvroSchema()).getType());

Review Comment:
   Addressed.



-- 
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]

Reply via email to