From 9890fa1fc07ea87879a0c4d506ade5b1f9cc689e Mon Sep 17 00:00:00 2001 From: cpwu Date: Sun, 24 Apr 2022 15:55:21 +0800 Subject: [PATCH] fix case --- tests/system-test/2-query/sum.py | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/tests/system-test/2-query/sum.py b/tests/system-test/2-query/sum.py index d50a840457..8a4130c466 100644 --- a/tests/system-test/2-query/sum.py +++ b/tests/system-test/2-query/sum.py @@ -21,8 +21,9 @@ BINARY_COL = "c8" NCHAR_COL = "c9" TS_COL = "c10" -NUM_COL = [INT_COL, BINT_COL, SINT_COL, TINT_COL, FLOAT_COL, DOUBLE_COL, BOOL_COL] -UN_NUM_COL = [BINARY_COL, NCHAR_COL, TS_COL] +NUM_COL = [INT_COL, BINT_COL, SINT_COL, TINT_COL, FLOAT_COL, DOUBLE_COL, ] +UN_NUM_COL = [BINARY_COL, NCHAR_COL, BOOL_COL] +TS_TYPE_COL = [TS_COL] class TDTestCase: @@ -40,7 +41,8 @@ class TDTestCase: ) ) sum_condition.extend( f"{num_col} + {num_col_2}" for num_col_2 in NUM_COL ) - sum_condition.extend( f"{num_col} + {un_num_col} " for un_num_col in [BINARY_COL, NCHAR_COL] ) + sum_condition.extend( f"{num_col} + {un_num_col} " for un_num_col in UN_NUM_COL ) + sum_condition.extend(f"{un_num_col} + {ts_col} " for un_num_col in UN_NUM_COL for ts_col in TS_TYPE_COL) return sum_condition @@ -75,7 +77,7 @@ class TDTestCase: ) ) sqls.extend( f"select sum( {un_num_col} + {un_num_col_2} ) from {tbanme} " for un_num_col_2 in UN_NUM_COL ) - sqls.extend( f"select sum( {num_col} + c10 ) from {tbanme} " for num_col in NUM_COL ) + sqls.extend( f"select sum( {num_col} + {ts_col} ) from {tbanme} " for num_col in NUM_COL for ts_col in TS_TYPE_COL) return sqls