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


##########
core/src/test/java/org/apache/iceberg/TestTrackedFileAdapters.java:
##########
@@ -671,6 +729,399 @@ void unknownSpecIdThrows() {
         .hasMessageContaining("Cannot find partition spec for spec ID");
   }
 
+  @Test
+  void dataTrackedFileAdapterHasNoTracking() {
+    TrackedFile result = 
TrackedFileAdapters.forDataFile(TABLE_SCHEMA).wrap(DATA_FILE);
+
+    assertThat(result.tracking()).isNull();
+    assertWrappedDataFileMatchesFileFields(result, DATA_FILE);
+    assertThatThrownBy(result::formatVersion)
+        .isInstanceOf(IllegalStateException.class)
+        .hasMessage("Format version is assigned at write time");
+  }
+
+  @Test
+  void dataTrackedFileAdapterFromAddedManifestEntry() {
+    TrackedFile result = 
TrackedFileAdapters.forDataFile(TABLE_SCHEMA).wrap(addedEntry(DATA_FILE));

Review Comment:
   Entry is pretty small so it would be great to just embed the information 
here rather than needing to go look at what `addedEntry` sets for defaults.



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