rdblue commented on code in PR #16769:
URL: https://github.com/apache/iceberg/pull/16769#discussion_r3463705488


##########
core/src/test/java/org/apache/iceberg/TestTrackedFileAdapters.java:
##########
@@ -399,28 +386,19 @@ private static PartitionData partition(String category) {
   }
 
   /** Minimal file with no tracking, used by the rejection and null-tracking 
tests. */
-  private static TrackedFileStruct trackedFile(FileContent contentType) {
-    return new TrackedFileStruct(
-        null,
-        contentType,
-        WRITER_FORMAT_VERSION,
-        "s3://bucket/file",
-        FileFormat.PARQUET,
-        NO_PARTITION,
-        1L,
-        1L);
+  private static TrackedFileStruct dummyTrackedFile(FileContent contentType) {
+    TrackedFileStruct file = new TrackedFileStruct();
+    file.set(CONTENT_TYPE_ORDINAL, contentType.id());

Review Comment:
   This introduces a bad practice, using the ordinals and the set methods. I'm 
surprised to see this change in the addition of builders. Instead, just update 
the usage of the constructor.



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

Reply via email to