rdblue commented on a change in pull request #3332:
URL: https://github.com/apache/iceberg/pull/3332#discussion_r733176756



##########
File path: 
spark/v3.0/spark3-extensions/src/test/java/org/apache/iceberg/spark/extensions/TestAddFilesProcedure.java
##########
@@ -735,4 +782,35 @@ private void createPartitionedHiveTable() {
     partitionedDF.write().insertInto(sourceTableName);
     partitionedDF.write().insertInto(sourceTableName);
   }
+
+  public List<Record> createOrcFile(File orcFile, int numRows) throws 
IOException {
+    // Needs to be deleted but depend on the rule to delete the file for us 
again at the end.
+    if (orcFile.exists()) {
+      orcFile.delete();
+    }
+    final org.apache.iceberg.Schema icebergSchema = new 
org.apache.iceberg.Schema(

Review comment:
       Is it possible to write to ORC without adding field IDs? We shouldn't 
allow importing files that already have field IDs, so if we disable that later 
that would cause this test to fail.
   
   What about creating a DataFrame and writing directly to ORC using Spark 
instead? That would probably be shorter, too.




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