You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@datafusion.apache.org by gi...@apache.org on 2026/10/06 15:48:34 UTC
(datafusion-comet) branch gh-readonly-queue/main/pr-6652-7821e4579eae2dc9d7379f7e78bdaa6ae690b161 created (now a32529c4d8)
This is an automated email from the ASF dual-hosted git repository.
github-merge-queue[bot] pushed a change to branch gh-readonly-queue/main/pr-6652-7821e4579eae2dc9d7379f7e78bdaa6ae690b161
in repository https://gitbox.apache.org/repos/asf/datafusion-comet.git
at a32529c4d8 test: move mixed-type shift coverage to SQL fixtures (#6652)
This branch includes the following new commits:
new a32529c4d8 test: move mixed-type shift coverage to SQL fixtures (#6652)
The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datafusion.apache.org
For additional commands, e-mail: commits-help@datafusion.apache.org
(datafusion-comet) 01/01: test: move mixed-type shift coverage to SQL fixtures (#6652)
Posted by gi...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
github-merge-queue[bot] pushed a commit to branch gh-readonly-queue/main/pr-6652-7821e4579eae2dc9d7379f7e78bdaa6ae690b161
in repository https://gitbox.apache.org/repos/asf/datafusion-comet.git
commit a32529c4d84f5157be7a23aa0742ecdc15090eb7
Author: KUAN-HAO HUANG <10...@users.noreply.github.com>
AuthorDate: Tue Oct 6 15:48:12 2026 +0000
test: move mixed-type shift coverage to SQL fixtures (#6652)
---
.../expressions/bitwise/shift_mixed_types.sql | 46 ++++++++++++++++++++++
.../apache/comet/CometBitwiseExpressionSuite.scala | 20 ----------
2 files changed, 46 insertions(+), 20 deletions(-)
diff --git a/spark/src/test/resources/sql-tests/expressions/bitwise/shift_mixed_types.sql b/spark/src/test/resources/sql-tests/expressions/bitwise/shift_mixed_types.sql
new file mode 100644
index 0000000000..a8100c4839
--- /dev/null
+++ b/spark/src/test/resources/sql-tests/expressions/bitwise/shift_mixed_types.sql
@@ -0,0 +1,46 @@
+-- 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.
+
+-- ConfigMatrix: parquet.enable.dictionary=false,true
+
+-- BIGINT values with INT amounts exercise Comet's cast of the shift amount.
+-- Migrated from CometBitwiseExpressionSuite's mixed-type shift test (#6634).
+statement
+CREATE TABLE test_shift_mixed_types(v bigint, amount int) USING parquet
+
+statement
+INSERT INTO test_shift_mixed_types
+SELECT /*+ COALESCE(1) */ v, amount
+FROM VALUES
+ (1111, 2),
+ (1111, 2),
+ (3333, 4),
+ (5555, 6),
+ (4294967296, 1),
+ (-4294967296, 1),
+ (9223372036854775807, 1),
+ (-9223372036854775808, 1),
+ (0, 0),
+ (NULL, 2),
+ (1111, NULL)
+AS input(v, amount)
+
+query
+SELECT shiftright(v, 2), shiftright(v, amount) FROM test_shift_mixed_types
+
+query
+SELECT shiftleft(v, 2), shiftleft(v, amount) FROM test_shift_mixed_types
diff --git a/spark/src/test/scala/org/apache/comet/CometBitwiseExpressionSuite.scala b/spark/src/test/scala/org/apache/comet/CometBitwiseExpressionSuite.scala
index 99a57b1575..db72532ee5 100644
--- a/spark/src/test/scala/org/apache/comet/CometBitwiseExpressionSuite.scala
+++ b/spark/src/test/scala/org/apache/comet/CometBitwiseExpressionSuite.scala
@@ -54,26 +54,6 @@ class CometBitwiseExpressionSuite extends CometTestBase with AdaptiveSparkPlanHe
}
}
- test("bitwise shift with different left/right types") {
- Seq(false, true).foreach { dictionary =>
- withSQLConf("parquet.enable.dictionary" -> dictionary.toString) {
- val table = "test"
- withTable(table) {
- sql(s"create table $table(col1 long, col2 int) using parquet")
- sql(s"insert into $table values(1111, 2)")
- sql(s"insert into $table values(1111, 2)")
- sql(s"insert into $table values(3333, 4)")
- sql(s"insert into $table values(5555, 6)")
-
- checkSparkAnswerAndOperator(
- s"SELECT shiftright(col1, 2), shiftright(col1, col2) FROM $table")
- checkSparkAnswerAndOperator(
- s"SELECT shiftleft(col1, 2), shiftleft(col1, col2) FROM $table")
- }
- }
- }
- }
-
test("bitwise_get - throws exceptions") {
def checkSparkAndCometEqualThrows(query: String): Unit = {
checkSparkAnswerMaybeThrows(sql(query)) match {
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datafusion.apache.org
For additional commands, e-mail: commits-help@datafusion.apache.org