You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues-all@impala.apache.org by "ASF subversion and git services (Jira)" <ji...@apache.org> on 2024/02/20 20:36:00 UTC

[jira] [Commented] (IMPALA-12814) VERIFY_IS_NOT_IN does not work with row_regex:

    [ https://issues.apache.org/jira/browse/IMPALA-12814?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17818988#comment-17818988 ] 

ASF subversion and git services commented on IMPALA-12814:
----------------------------------------------------------

Commit 49126532952f9cee1fab460e94d4c9db6e856073 in impala's branch refs/heads/master from Joe McDonnell
[ https://gitbox.apache.org/repos/asf?p=impala.git;h=491265329 ]

IMPALA-12814: Allow use of row_regex for VERIFY_IS_NOT_IN

This adds support for using "row_regex:" entries in the
VERIFY_IS_NOT_IN sections. There are existing tests that
already use this formula, but it doesn't actually match
using the regex. This fixes test_result_verifier.py's
verify_query_result_is_not_in() to detect the regexes and
use regex logic for the check.

Testing:
 - Hand tested by adding a "row_regex:.*" to a VERIFY_IS_NOT_IN
   section and verifying it produces an error.
 - Hand tested by adding a "row_regex:match_nothing.*" to
   make sure nothing matched it.

Change-Id: Id856ae7de9727adeaec9487c7bd0c2b81c8e8b37
Reviewed-on: http://gerrit.cloudera.org:8080/21036
Tested-by: Impala Public Jenkins <im...@cloudera.com>
Reviewed-by: Michael Smith <mi...@cloudera.com>


> VERIFY_IS_NOT_IN does not work with row_regex:
> ----------------------------------------------
>
>                 Key: IMPALA-12814
>                 URL: https://issues.apache.org/jira/browse/IMPALA-12814
>             Project: IMPALA
>          Issue Type: Bug
>          Components: Infrastructure
>    Affects Versions: Impala 4.3.0
>            Reporter: Joe McDonnell
>            Priority: Major
>
> When testing some changes that would add content to explain plan, I see that VERIFY_IS_NOT_IN does not work with row_regex. Here is a trivial case that should always fail:
> {noformat}
> ---- RESULTS: VERIFY_IS_NOT_IN
> row_regex:.*{noformat}
> It does not fail. It looks like it is doing set logic without paying attention to row_regex:
> {noformat}
> def verify_query_result_is_not_in(expected_results, actual_results):
>   assert_args_not_none(expected_results, actual_results)
>   expected_set = set(map(unicode, expected_results.rows))
>   actual_set = set(map(unicode, actual_results.rows))
>   assert expected_set.isdisjoint(actual_set){noformat}
> [https://github.com/apache/impala/blob/b15d6dc2e7df05392a1daa4bc1b3da9ca31a583b/tests/common/test_result_verifier.py#L298-L302]
> It looks like some existing test cases use it this way.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-all-unsubscribe@impala.apache.org
For additional commands, e-mail: issues-all-help@impala.apache.org