[
https://issues.apache.org/jira/browse/CALCITE-6957?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17944943#comment-17944943
]
Zhen Chen commented on CALCITE-6957:
------------------------------------
[~nobigo] Hi, I think recording PRs in the description doesn't clearly capture
issues because PRs can be updated. It would be better to reference a specific
commit or describe the problem in detail.
For example:
In RelOptRulesTest.xml, you can add the following XML, but the
RelOptRulesTest.java file doesn't actually contain a
{{testUnionEliminatorRule}} method, yet the entire test still passes. This is
incorrect.
{code:java}
<TestCase name="testUnionEliminatorRule">
<Resource name="sql">
<![CDATA[select name, deptno from dept
union all
(select name, deptno from
(values ('1', 2)) as t(name, deptno)
where t.deptno < 0)]]>
</Resource>
<Resource name="planBefore">
<![CDATA[
LogicalUnion(all=[true])
LogicalTableScan(table=[[scott, DEPT]])
]]>
</Resource>
<Resource name="planAfter">
<![CDATA[
LogicalTableScan(table=[[scott, DEPT]])
]]>
</Resource> {code}
> The RelOptRulesTest tests should fail if the xml file contains tests that do
> not exist in Java
> ----------------------------------------------------------------------------------------------
>
> Key: CALCITE-6957
> URL: https://issues.apache.org/jira/browse/CALCITE-6957
> Project: Calcite
> Issue Type: Bug
> Reporter: xiong duan
> Priority: Major
>
> According to PR https://github.com/apache/calcite/pull/4304, the unit test
> should fail when there are redundant testUnionEliminatorRule test cases in
> RelOptRulesTest.xml, but it is successful now.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)