This is an automated email from the ASF dual-hosted git repository.

viirya pushed a commit to branch branch-3.2
in repository https://gitbox.apache.org/repos/asf/spark.git


The following commit(s) were added to refs/heads/branch-3.2 by this push:
     new 2d75b99  [SPARK-36670][SQL][TEST][FOLLOWUP] Add AvroCodecSuite
2d75b99 is described below

commit 2d75b99b970bdab55646151328e20974bdfae27f
Author: Liang-Chi Hsieh <vii...@gmail.com>
AuthorDate: Wed Sep 8 22:17:35 2021 -0700

    [SPARK-36670][SQL][TEST][FOLLOWUP] Add AvroCodecSuite
    
    ### What changes were proposed in this pull request?
    
    This patch proposes to add also `AvroCodecSuite` as a follow up for 
SPARK-36670.
    
    ### Why are the changes needed?
    
    Improve test coverage.
    
    ### Does this PR introduce _any_ user-facing change?
    
    No
    
    ### How was this patch tested?
    
    Added test.
    
    Closes #33939 from viirya/SPARK-36670-avro.
    
    Authored-by: Liang-Chi Hsieh <vii...@gmail.com>
    Signed-off-by: Liang-Chi Hsieh <vii...@gmail.com>
    (cherry picked from commit c95d3fe6c98ef1a4b1b68a5243ad7c87a1edcbcc)
    Signed-off-by: Liang-Chi Hsieh <vii...@gmail.com>
---
 .../org/apache/spark/sql/avro/AvroCodecSuite.scala | 29 ++++++++++++++++++++++
 1 file changed, 29 insertions(+)

diff --git 
a/external/avro/src/test/scala/org/apache/spark/sql/avro/AvroCodecSuite.scala 
b/external/avro/src/test/scala/org/apache/spark/sql/avro/AvroCodecSuite.scala
new file mode 100644
index 0000000..9a4bcc6
--- /dev/null
+++ 
b/external/avro/src/test/scala/org/apache/spark/sql/avro/AvroCodecSuite.scala
@@ -0,0 +1,29 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *    http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.spark.sql.avro
+
+import org.apache.spark.sql.execution.datasources.FileSourceCodecSuite
+import org.apache.spark.sql.internal.SQLConf
+
+class AvroCodecSuite extends FileSourceCodecSuite {
+
+  override def format: String = "avro"
+  override val codecConfigName: String = SQLConf.AVRO_COMPRESSION_CODEC.key
+  override protected def availableCodecs = Seq("uncompressed", "deflate", 
"snappy",
+    "bzip2", "xz", "zstandard")
+}

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@spark.apache.org
For additional commands, e-mail: commits-h...@spark.apache.org

Reply via email to