You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@iceberg.apache.org by "chenjian2664 (via GitHub)" <gi...@apache.org> on 2025/10/06 14:56:27 UTC
Re: [PR] Core: Use time-travel schema when resolving partition spec in scan [iceberg]
chenjian2664 commented on code in PR #13301:
URL: https://github.com/apache/iceberg/pull/13301#discussion_r2406824589
##########
core/src/test/java/org/apache/iceberg/TestScansAndSchemaEvolution.java:
##########
@@ -113,4 +118,48 @@ public void testPartitionSourceRename() throws IOException {
assertThat(tasks).hasSize(1);
}
+
+ @TestTemplate
+ public void testColumnRenameOrDrop() throws IOException {
+ File location = Files.createTempDirectory(temp, "junit").toFile();
+ assertThat(location.delete()).isTrue(); // should be created by table create
+
+ Table table = TestTables.create(location, "test", SCHEMA, SPEC, formatVersion);
+
+ DataFile fileOne = createDataFile("one");
+ DataFile fileTwo = createDataFile("two");
+
+ table.newAppend().appendFile(fileOne).appendFile(fileTwo).commit();
+ long firstSnapshotId = table.currentSnapshot().snapshotId();
+
+ table.updateSchema().renameColumn("data", "renamed_data").commit();
Review Comment:
see `testPartitionSourceRename`, added the test case for it
--
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-unsubscribe@iceberg.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org