Mulily0513 commented on code in PR #22:
URL: https://github.com/apache/cloudberry-pxf/pull/22#discussion_r2647618562


##########
automation/src/test/java/org/greenplum/pxf/automation/features/hive/HiveBaseTest.java:
##########
@@ -371,25 +371,11 @@ void loadDataIntoHive(String fileName, HiveTable 
tableName) throws Exception {
 
     void loadDataIntoHive(Hdfs hdfs, Hive hive, String fileName, HiveTable 
tableName) throws Exception {
 
-        String localPath = localDataResourcesFolder + "/hive/" + fileName;
-        String hdfsPath = hdfs.getWorkingDirectory() + "/" + fileName;
-
-        // Verify local file exists
-        java.io.File localFile = new java.io.File(localPath);
-        if (!localFile.exists()) {
-            throw new RuntimeException("Local file does not exist: " + 
localFile.getAbsolutePath());
-        }
-
         // copy data to hdfs
-        hdfs.copyFromLocal(localPath, hdfsPath);
-
-        // Verify file was copied to HDFS
-        if (!hdfs.doesFileExist(hdfsPath)) {
-            throw new RuntimeException("File was not copied to HDFS: " + 
hdfsPath);
-        }
-        
+        hdfs.copyFromLocal(localDataResourcesFolder + "/hive/" + fileName,
+                hdfs.getWorkingDirectory() + "/" + fileName);
         // load to hive table
-        hive.loadData(tableName, hdfsPath, false);
+        hive.loadData(tableName, hdfs.getWorkingDirectory() + "/" + fileName, 
false);

Review Comment:
   ok



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