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/07/22 18:26:27 UTC

(datafusion) branch gh-readonly-queue/main/pr-23757-ddd1cd260b34e7e1cfa712dd4ae6834381a60fae created (now b102d0497b)

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-23757-ddd1cd260b34e7e1cfa712dd4ae6834381a60fae
in repository https://gitbox.apache.org/repos/asf/datafusion.git


      at b102d0497b test: improve `md5` function SQL test coverage (#23757)

This branch includes the following new commits:

     new b102d0497b test: improve `md5` function SQL test coverage (#23757)

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) 01/01: test: improve `md5` function SQL test coverage (#23757)

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-23757-ddd1cd260b34e7e1cfa712dd4ae6834381a60fae
in repository https://gitbox.apache.org/repos/asf/datafusion.git

commit b102d0497be92467036b107c1e0df7ef17cfe16b
Author: Yongting You <20...@gmail.com>
AuthorDate: Thu Jul 23 02:26:05 2026 +0800

    test: improve `md5` function SQL test coverage (#23757)
    
    ## Which issue does this PR close?
    
    <!--
    We generally require a GitHub issue to be filed for all bug fixes and
    enhancements and this helps us generate change logs for our releases.
    You can link an issue to this PR using the GitHub syntax. For example
    `Closes #123` indicates that this PR will close issue #123.
    -->
    
    - Closes #.
    
    ## Rationale for this change
    
    <!--
    Why are you proposing this change? If this is already explained clearly
    in the issue then this section is not needed.
    Explaining clearly why changes are proposed helps reviewers understand
    your changes and offer better suggestions for fixes.
    -->
    Codecov reports low test coverage for this function, so this PR adds
    more SLT tests for it.
    
    The tests were AI-generated, and I manually verified that the results
    are correct.
    
    See `Codecov` bot comment -> `☔ View full report in Codecov by Harness`
    -> `Indirect Changes` for the updated test coverage.
    
    ## What changes are included in this PR?
    
    <!--
    There is no need to duplicate the description in the issue here but it
    is sometimes worth providing a summary of the individual changes in this
    PR.
    -->
    
    ## Are these changes tested?
    
    <!--
    We typically require tests for all PRs in order to:
    1. Prevent the code from being accidentally broken by subsequent changes
    2. Serve as another way to document the expected behavior of the code
    
    If tests are not included in your PR, please explain why (for example,
    are they covered by existing tests)?
    -->
    
    ## Are there any user-facing changes?
    
    <!--
    If there are user-facing changes then we may require documentation to be
    updated before approving the PR.
    -->
    
    <!--
    If there are any breaking changes to public APIs, please add the `api
    change` label.
    -->
---
 datafusion/sqllogictest/test_files/expr.slt | 24 ++++++++++++++++++++++++
 1 file changed, 24 insertions(+)

diff --git a/datafusion/sqllogictest/test_files/expr.slt b/datafusion/sqllogictest/test_files/expr.slt
index c7c997f330..e14004a5f9 100644
--- a/datafusion/sqllogictest/test_files/expr.slt
+++ b/datafusion/sqllogictest/test_files/expr.slt
@@ -1559,6 +1559,30 @@ SELECT md5(NULL);
 ----
 NULL
 
+# md5 string and binary array inputs
+query BBBBBB
+SELECT
+  md5(column1) = md5('tom'),
+  md5(arrow_cast(column1, 'LargeUtf8')) = md5('tom'),
+  md5(arrow_cast(column1, 'Utf8View')) = md5('tom'),
+  md5(arrow_cast(column1, 'Binary')) = md5('tom'),
+  md5(arrow_cast(column1, 'LargeBinary')) = md5('tom'),
+  md5(arrow_cast(column1, 'BinaryView')) = md5('tom')
+FROM (VALUES ('tom'), (NULL)) AS t(column1);
+----
+true true true true true true
+NULL NULL NULL NULL NULL NULL
+
+# invalid argument count and type
+query error DataFusion error:
+SELECT md5();
+
+query error DataFusion error:
+SELECT md5('tom', 'extra');
+
+query error DataFusion error:
+SELECT md5(1);
+
 query ?
 SELECT digest('','md5');
 ----


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datafusion.apache.org
For additional commands, e-mail: commits-help@datafusion.apache.org