sarutak commented on a change in pull request #31721:
URL: https://github.com/apache/spark/pull/31721#discussion_r589581473



##########
File path: 
sql/hive/src/test/scala/org/apache/spark/sql/hive/execution/HiveQuerySuite.scala
##########
@@ -857,6 +857,31 @@ class HiveQuerySuite extends HiveComparisonTest with 
SQLTestUtils with BeforeAnd
     assert(sql(s"list file $testFile").count() == 1)
   }
 
+  test("ADD ARCHIVE command") {
+    withTempDir { dir =>
+      val file = File.createTempFile("someprefix1", "somesuffix1", dir)
+      val zipFile = new File(dir, "test.zip")
+      TestUtils.createJar(Seq(file), zipFile)
+      sql(s"ADD ARCHIVE ${zipFile.getAbsolutePath}#foo")
+
+      val checkAddArchive =
+        sparkContext.parallelize(
+          Seq(
+            "foo",
+            s"foo/${file.getName}"), 1).map { name =>
+          (name, new File(SparkFiles.get(name)).canRead)
+        }.collect()
+
+      assert(checkAddArchive(0) === ("foo", true))
+      assert(checkAddArchive(1) === (s"foo/${file.getName}", true))
+      assert(sql("list archives").

Review comment:
       There are `list file`, `list files`, `list jar` and `list jars` in this 
file.
   I don't think it's a matter but If you think it's really necessary them to 
be upper case, I'll fix including them.




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

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