This is an automated email from the ASF dual-hosted git repository.
duanzhengqiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/shardingsphere.git
The following commit(s) were added to refs/heads/master by this push:
new 72da57f48b3 Add datetime type convert e2e test (#31058)
72da57f48b3 is described below
commit 72da57f48b31cbaef4908cf4fb56f6226bfa4617
Author: niu niu <[email protected]>
AuthorDate: Tue Apr 30 07:45:14 2024 +0800
Add datetime type convert e2e test (#31058)
* Add datetime type convert e2e test
* Add assertion
* Fix
* Fix
---
.../src/test/resources/cases/dql/dql-integration-select.xml | 12 ++++++++++--
1 file changed, 10 insertions(+), 2 deletions(-)
diff --git
a/test/e2e/sql/src/test/resources/cases/dql/dql-integration-select.xml
b/test/e2e/sql/src/test/resources/cases/dql/dql-integration-select.xml
index 9198cf2455a..2b3e2ddf492 100644
--- a/test/e2e/sql/src/test/resources/cases/dql/dql-integration-select.xml
+++ b/test/e2e/sql/src/test/resources/cases/dql/dql-integration-select.xml
@@ -26,11 +26,11 @@
</test-case>
<test-case sql="SELECT 1=1, 1!=1" db-types="MySQL"
scenario-types="db_tbl_sql_federation" >
- <assertion />
+ <assertion expected-data-source-name="read_dataset" />
</test-case>
<test-case sql="SELECT 1=1, 1!=1, 1>1, 1<1, 1>=1, 1<=1"
db-types="MySQL" scenario-types="db_tbl_sql_federation" >
- <assertion />
+ <assertion expected-data-source-name="read_dataset" />
</test-case>
<test-case sql="SELECT * FROM t_order WHERE remark LIKE '%张%'"
db-types="MySQL,PostgreSQL,openGauss" scenario-types="db_tbl_sql_federation" >
@@ -268,4 +268,12 @@
<test-case sql="select * from shardingsphere.cluster_information;"
db-types="MySQL,PostgreSQL,openGauss" scenario-types="db">
<assertion expected-data-file="select_cluster_information.xml" />
</test-case>
+
+ <test-case sql="SELECT type_datetime FROM t_product_extend"
db-types="MySQL" scenario-types="db_tbl_sql_federation">
+ <assertion expected-data-source-name="read_dataset" />
+ </test-case>
+
+ <test-case sql="SELECT result.max_datetime FROM (SELECT MAX(type_datetime)
AS max_datetime FROM t_product_extend) result" db-types="MySQL"
scenario-types="db_tbl_sql_federation">
+ <assertion expected-data-source-name="read_dataset" />
+ </test-case>
</integration-test-cases>