Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
taosdata
TDengine
提交
602b1b74
TDengine
项目概览
taosdata
/
TDengine
大约 1 年 前同步成功
通知
1184
Star
22015
Fork
4786
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
1
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
TDengine
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
1
Issue
1
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
602b1b74
编写于
4月 20, 2023
作者:
L
liuyao
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
add test loop
上级
9d6e8b3f
变更
6
隐藏空白更改
内联
并排
Showing
6 changed file
with
189 addition
and
97 deletion
+189
-97
tests/script/tsim/stream/deleteInterval.sim
tests/script/tsim/stream/deleteInterval.sim
+15
-15
tests/script/tsim/stream/fillHistoryBasic3.sim
tests/script/tsim/stream/fillHistoryBasic3.sim
+6
-6
tests/script/tsim/stream/partitionbyColumnInterval.sim
tests/script/tsim/stream/partitionbyColumnInterval.sim
+14
-14
tests/script/tsim/stream/partitionbyColumnSession.sim
tests/script/tsim/stream/partitionbyColumnSession.sim
+15
-15
tests/script/tsim/stream/session1.sim
tests/script/tsim/stream/session1.sim
+65
-29
tests/script/tsim/stream/triggerSession0.sim
tests/script/tsim/stream/triggerSession0.sim
+74
-18
未找到文件。
tests/script/tsim/stream/deleteInterval.sim
浏览文件 @
602b1b74
...
...
@@ -29,7 +29,7 @@ sleep 1000
sql select * from streamt order by c1, c2, c3;
$loop_count = $loop_count + 1
if $loop_count ==
1
0 then
if $loop_count ==
3
0 then
return -1
endi
...
...
@@ -47,7 +47,7 @@ sleep 1000
sql select * from streamt order by c1, c2, c3;
$loop_count = $loop_count + 1
if $loop_count ==
1
0 then
if $loop_count ==
3
0 then
return -1
endi
...
...
@@ -76,7 +76,7 @@ sleep 1000
sql select * from streamt order by c1, c2, c3;
$loop_count = $loop_count + 1
if $loop_count ==
1
0 then
if $loop_count ==
3
0 then
return -1
endi
...
...
@@ -102,7 +102,7 @@ sleep 1000
sql select * from streamt order by c1, c2, c3;
$loop_count = $loop_count + 1
if $loop_count ==
1
0 then
if $loop_count ==
3
0 then
return -1
endi
...
...
@@ -122,7 +122,7 @@ sleep 1000
sql select * from streamt order by c1, c2, c3;
$loop_count = $loop_count + 1
if $loop_count ==
1
0 then
if $loop_count ==
3
0 then
return -1
endi
...
...
@@ -160,7 +160,7 @@ sleep 1000
sql select * from streamt order by c1, c2, c3;
$loop_count = $loop_count + 1
if $loop_count ==
1
0 then
if $loop_count ==
3
0 then
return -1
endi
...
...
@@ -205,7 +205,7 @@ sleep 1000
sql select * from test.streamt2 order by c1, c2, c3;
$loop_count = $loop_count + 1
if $loop_count ==
1
0 then
if $loop_count ==
3
0 then
return -1
endi
...
...
@@ -226,7 +226,7 @@ sleep 1000
sql select * from test.streamt2 order by c1, c2, c3;
$loop_count = $loop_count + 1
if $loop_count ==
1
0 then
if $loop_count ==
3
0 then
return -1
endi
...
...
@@ -260,7 +260,7 @@ sleep 1000
sql select * from test.streamt2 order by c1, c2, c3;
$loop_count = $loop_count + 1
if $loop_count ==
1
0 then
if $loop_count ==
3
0 then
return -1
endi
...
...
@@ -295,7 +295,7 @@ sleep 1000
sql select * from test.streamt2 order by c1, c2, c3;
$loop_count = $loop_count + 1
if $loop_count ==
1
0 then
if $loop_count ==
3
0 then
return -1
endi
...
...
@@ -334,7 +334,7 @@ sleep 1000
sql select * from test.streamt2 order by c1, c2, c3;
$loop_count = $loop_count + 1
if $loop_count ==
1
0 then
if $loop_count ==
3
0 then
return -1
endi
...
...
@@ -384,7 +384,7 @@ sleep 1000
sql select * from test.streamt2 order by c1, c2, c3;
$loop_count = $loop_count + 1
if $loop_count ==
1
0 then
if $loop_count ==
3
0 then
return -1
endi
...
...
@@ -433,7 +433,7 @@ sleep 1000
sql select * from test.streamt3 order by c1, c2, c3;
$loop_count = $loop_count + 1
if $loop_count ==
1
0 then
if $loop_count ==
3
0 then
return -1
endi
...
...
@@ -451,7 +451,7 @@ sleep 1000
sql select * from test.streamt3 order by c1, c2, c3;
$loop_count = $loop_count + 1
if $loop_count ==
1
0 then
if $loop_count ==
3
0 then
return -1
endi
...
...
@@ -469,7 +469,7 @@ sleep 1000
sql select * from test.streamt3 order by c1, c2, c3;
$loop_count = $loop_count + 1
if $loop_count ==
1
0 then
if $loop_count ==
3
0 then
return -1
endi
...
...
tests/script/tsim/stream/fillHistoryBasic3.sim
浏览文件 @
602b1b74
...
...
@@ -4,7 +4,7 @@ looptest:
system sh/stop_dnodes.sh
system sh/deploy.sh -n dnode1 -i 1
system sh/exec.sh -n dnode1 -s start
sleep
5
0
sleep
100
0
sql connect
sql create database test vgroups 1;
...
...
@@ -24,7 +24,7 @@ sleep 3000
$loop_count = 0
loop7:
sleep
5
0
sleep
100
0
sql select * from test.streamt2 order by c1, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -48,7 +48,7 @@ sql insert into t2 values(1648791213000,1,2,3,1.0);
$loop_count = 0
loop8:
sleep
5
0
sleep
100
0
sql select * from test.streamt2 order by c1, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -72,7 +72,7 @@ sql insert into t2 values(1648791213000,2,2,3,1.0);
$loop_count = 0
loop9:
sleep
5
0
sleep
100
0
sql select * from test.streamt2 order by c1, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -102,7 +102,7 @@ sql insert into t2 values(1648791213002,1,2,3,1.0);
$loop_count = 0
loop10:
sleep
5
0
sleep
100
0
sql select * from test.streamt2 order by c1, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -144,7 +144,7 @@ sql insert into t2 values(1648791213001,1,2,3,1.0) (1648791223001,2,2,3,1.0) (16
$loop_count = 0
loop11:
sleep
5
0
sleep
100
0
sql select * from test.streamt2 order by c1, c2, c3;
$loop_count = $loop_count + 1
...
...
tests/script/tsim/stream/partitionbyColumnInterval.sim
浏览文件 @
602b1b74
...
...
@@ -4,7 +4,7 @@ looptest:
system sh/stop_dnodes.sh
system sh/deploy.sh -n dnode1 -i 1
system sh/exec.sh -n dnode1 -s start
sleep
5
0
sleep
100
0
sql connect
sql drop stream if exists streams0;
...
...
@@ -24,7 +24,7 @@ sql insert into t1 values(1648791213000,NULL,NULL,NULL,NULL);
$loop_count = 0
loop0:
sleep
5
0
sleep
100
0
sql select * from streamt order by c1, c4, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -48,7 +48,7 @@ sql insert into t1 values(1648791213000,1,2,3,1.0);
$loop_count = 0
loop1:
sleep
5
0
sleep
100
0
sql select * from streamt order by c1, c4, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -71,7 +71,7 @@ sql insert into t1 values(1648791213000,2,2,3,1.0);
$loop_count = 0
loop2:
sleep
5
0
sleep
100
0
sql select * from streamt order by c1, c4, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -97,7 +97,7 @@ sql insert into t1 values(1648791213002,1,2,3,1.0);
$loop_count = 0
loop3:
sleep
5
0
sleep
100
0
sql select * from streamt order by c1, c4, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -134,7 +134,7 @@ sql insert into t1 values(1648791213001,1,2,3,1.0) (1648791223001,2,2,3,1.0) (16
$loop_count = 0
loop4:
sleep
5
0
sleep
100
0
sql select * from streamt order by c1, c4, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -208,7 +208,7 @@ sql insert into t1 values(1648791213001,1,2,3,2.0);
$loop_count = 0
loop5:
sleep
5
0
sleep
100
0
sql select * from streamt1 order by c1, c4, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -229,7 +229,7 @@ sql insert into t1 values(1648791213001,1,1,6,2.0) (1648791223002,1,1,7,2.0);
$loop_count = 0
loop6:
sleep
5
0
sleep
100
0
sql select * from streamt1 order by c1, c4, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -294,7 +294,7 @@ sql insert into t2 values(1648791213000,NULL,NULL,NULL,NULL);
$loop_count = 0
loop7:
sleep
5
0
sleep
100
0
sql select * from test.streamt2 order by c1, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -318,7 +318,7 @@ sql insert into t2 values(1648791213000,1,2,3,1.0);
$loop_count = 0
loop8:
sleep
5
0
sleep
100
0
sql select * from test.streamt2 order by c1, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -342,7 +342,7 @@ sql insert into t2 values(1648791213000,2,2,3,1.0);
$loop_count = 0
loop9:
sleep
5
0
sleep
100
0
sql select * from test.streamt2 order by c1, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -590,7 +590,7 @@ sql delete from st where ts = 1648791223000;
$loop_count = 0
loop15:
sleep
5
0
sleep
100
0
sql select * from test.streamt5 order by c1, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -615,7 +615,7 @@ sql delete from st where ts = 1648791223001;
$loop_count = 0
loop16:
sleep
5
0
sleep
100
0
sql select * from test.streamt5 order by c1, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -640,7 +640,7 @@ sql delete from st where ts = 1648791223001;
$loop_count = 0
loop17:
sleep
5
0
sleep
100
0
sql select * from test.streamt5 order by c1, c2, c3;
$loop_count = $loop_count + 1
...
...
tests/script/tsim/stream/partitionbyColumnSession.sim
浏览文件 @
602b1b74
...
...
@@ -4,7 +4,7 @@ looptest:
system sh/stop_dnodes.sh
system sh/deploy.sh -n dnode1 -i 1
system sh/exec.sh -n dnode1 -s start
sleep
5
0
sleep
100
0
sql connect
sql drop stream if exists streams0;
...
...
@@ -24,7 +24,7 @@ sql insert into t1 values(1648791213000,NULL,NULL,NULL,NULL);
$loop_count = 0
loop0:
sleep
5
0
sleep
100
0
sql select * from streamt order by c1, c4, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -48,7 +48,7 @@ sql insert into t1 values(1648791213000,1,2,3,1.0);
$loop_count = 0
loop1:
sleep
5
0
sleep
100
0
sql select * from streamt order by c1, c4, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -71,7 +71,7 @@ sql insert into t1 values(1648791213000,2,2,3,1.0);
$loop_count = 0
loop2:
sleep
5
0
sleep
100
0
sql select * from streamt order by c1, c4, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -97,7 +97,7 @@ sql insert into t1 values(1648791213002,1,2,3,1.0);
$loop_count = 0
loop3:
sleep
5
0
sleep
100
0
sql select * from streamt order by c1, c4, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -134,7 +134,7 @@ sql insert into t1 values(1648791213001,1,2,3,1.0) (1648791223001,2,2,3,1.0) (16
$loop_count = 0
loop4:
sleep
5
0
sleep
100
0
sql select * from streamt order by c1, c4, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -207,7 +207,7 @@ sql insert into t1 values(1648791213001,1,2,3,2.0);
$loop_count = 0
loop5:
sleep
5
0
sleep
100
0
sql select * from streamt1 order by c1, c4, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -228,7 +228,7 @@ sql insert into t1 values(1648791213001,1,1,6,2.0) (1648791223002,1,1,7,2.0);
$loop_count = 0
loop6:
sleep
5
0
sleep
100
0
sql select * from streamt1 order by c1, c4, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -292,7 +292,7 @@ sql insert into t2 values(1648791213000,NULL,NULL,NULL,NULL);
$loop_count = 0
loop7:
sleep
5
0
sleep
100
0
sql select * from test.streamt2 order by c1, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -316,7 +316,7 @@ sql insert into t2 values(1648791213000,1,2,3,1.0);
$loop_count = 0
loop8:
sleep
5
0
sleep
100
0
sql select * from test.streamt2 order by c1, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -340,7 +340,7 @@ sql insert into t2 values(1648791213000,2,2,3,1.0);
$loop_count = 0
loop9:
sleep
5
0
sleep
100
0
sql select * from test.streamt2 order by c1, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -370,7 +370,7 @@ sql insert into t2 values(1648791213002,1,2,3,1.0);
$loop_count = 0
loop10:
sleep
5
0
sleep
100
0
sql select * from test.streamt2 order by c1, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -412,7 +412,7 @@ sql insert into t2 values(1648791213001,1,2,3,1.0) (1648791223001,2,2,3,1.0) (16
$loop_count = 0
loop11:
sleep
5
0
sleep
100
0
sql select * from test.streamt2 order by c1, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -489,7 +489,7 @@ sql insert into t4 values(1648791213000,1,2,3,1.0);
$loop_count = 0
loop13:
sleep
5
0
sleep
100
0
sql select * from test.streamt4 order by c1, c2, c3;
$loop_count = $loop_count + 1
...
...
@@ -531,7 +531,7 @@ sql insert into t1 values(1648791213000,1,2,3,1.0);
$loop_count = 0
loop14:
sleep
5
0
sleep
100
0
sql select * from test.streamt4 order by c1, c2, c3;
$loop_count = $loop_count + 1
...
...
tests/script/tsim/stream/session1.sim
浏览文件 @
602b1b74
...
...
@@ -22,77 +22,95 @@ sql insert into t1 values(1648791210000,1,1,1,1.1,1);
sql insert into t1 values(1648791220000,2,2,2,2.1,2);
sql insert into t1 values(1648791230000,3,3,3,3.1,3);
sql insert into t1 values(1648791240000,4,4,4,4.1,4);
$loop_count = 0
loop0:
sleep 1000
$loop_count = $loop_count + 1
if $loop_count == 10 then
return -1
endi
sql select * from streamt order by s desc;
# row 0
if $data01 != 4 then
print ======$data01
return -1
goto loop0
endi
if $data02 != 10 then
print ======$data02
return -1
goto loop0
endi
if $data03 != 1 then
print ======$data03
return -1
goto loop0
endi
if $data04 != 4 then
print ======$data04
return -1
goto loop0
endi
sql insert into t1 values(1648791250005,5,5,5,5.1,5);
sql insert into t1 values(1648791260006,6,6,6,6.1,6);
sql insert into t1 values(1648791270007,7,7,7,7.1,7);
sql insert into t1 values(1648791240005,5,5,5,5.1,8) (1648791250006,6,6,6,6.1,9);
$loop_count = 0
loop1:
sleep 1000
$loop_count = $loop_count + 1
if $loop_count == 10 then
return -1
endi
sql select * from streamt order by s desc;
# row 0
if $data01 != 8 then
print ======$data01
return -
1
goto loop
1
endi
if $data02 != 32 then
print ======$data02
return -
1
goto loop
1
endi
if $data03 != 1 then
print ======$data03
return -
1
goto loop
1
endi
if $data04 != 9 then
print ======$data04
return -
1
goto loop
1
endi
# row 1
if $data11 != 1 then
print ======$data11
return -
1
goto loop
1
endi
if $data12 != 7 then
print ======$data12
return -
1
goto loop
1
endi
if $data13 != 7 then
print ======$data13
return -
1
goto loop
1
endi
if $data14 != 7 then
print ======$data14
return -
1
goto loop
1
endi
sql insert into t1 values(1648791280008,7,7,7,7.1,10) (1648791300009,8,8,8,8.1,11);
...
...
@@ -100,101 +118,119 @@ sql insert into t1 values(1648791260007,7,7,7,7.1,12) (1648791290008,7,7,7,7.1,1
sql insert into t1 values(1648791500000,7,7,7,7.1,15) (1648791520000,8,8,8,8.1,16) (1648791540000,8,8,8,8.1,17);
sql insert into t1 values(1648791530000,8,8,8,8.1,18);
sql insert into t1 values(1648791220000,10,10,10,10.1,19) (1648791290008,2,2,2,2.1,20) (1648791540000,17,17,17,17.1,21) (1648791500001,22,22,22,22.1,22);
$loop_count = 0
loop2:
sleep 1000
$loop_count = $loop_count + 1
if $loop_count == 10 then
return -1
endi
sql select * from streamt order by s desc;
# row 0
if $data01 != 2 then
print ======$data01
return -1
goto loop2
endi
if $data02 != 29 then
print ======$data02
return -1
goto loop2
endi
if $data03 != 7 then
print ======$data03
return -1
goto loop2
endi
if $data04 != 22 then
print ======$data04
return -1
goto loop2
endi
# row 1
if $data11 != 3 then
print ======$data11
return -1
goto loop2
endi
if $data12 != 33 then
print ======$data12
return -1
goto loop2
endi
if $data13 != 8 then
print ======$data13
return -1
goto loop2
endi
if $data14 != 21 then
print ======$data14
return -1
goto loop2
endi
# row 2
if $data21 != 4 then
print ======$data21
return -1
goto loop2
endi
if $data22 != 25 then
print ======$data22
return -1
goto loop2
endi
if $data23 != 2 then
print ======$data23
return -1
goto loop2
endi
if $data24 != 20 then
print ======$data24
return -1
goto loop2
endi
# row 3
if $data31 != 10 then
print ======$data31
return -1
goto loop2
endi
if $data32 != 54 then
print ======$data32
return -1
goto loop2
endi
if $data33 != 1 then
print ======$data33
return -1
goto loop2
endi
if $data34 != 19 then
print ======$data34
return -1
goto loop2
endi
sql insert into t1 values(1648791000000,1,1,1,1.1,23);
$loop_count = 0
loop3:
sleep 1000
$loop_count = $loop_count + 1
if $loop_count == 10 then
return -1
endi
sql select * from streamt order by s desc;
# row 0
if $data01 != 1 then
print ======$data01
return -1
goto loop3
endi
sql create database test1 vgroups 1;
...
...
tests/script/tsim/stream/triggerSession0.sim
浏览文件 @
602b1b74
...
...
@@ -22,79 +22,135 @@ sql insert into t2 values(1648791222999,1,2,3,1.0);
sql insert into t2 values(1648791223000,1,2,3,1.0);
sql insert into t2 values(1648791223001,1,2,3,1.0);
sql insert into t2 values(1648791233001,1,2,3,1.0);
sleep 2000
$loop_count = 0
loop0:
sleep 1000
$loop_count = $loop_count + 1
if $loop_count == 20 then
return -1
endi
sql select * from streamt2;
if $rows != 0 then
print ======$rows
return -1
goto loop0
endi
sql insert into t2 values(1648791243002,1,2,3,1.0);
sleep 2000
loop1:
sleep 1000
$loop_count = $loop_count + 1
if $loop_count == 20 then
return -1
endi
sql select * from streamt2;
if $rows != 1 then
print ======$rows
return -
1
goto loop
1
endi
if $data01 != 5 then
print ======$data01
return -
1
goto loop
1
endi
sql insert into t2 values(1648791223001,1,2,3,1.0) (1648791223002,1,2,3,1.0) (1648791222999,1,2,3,1.0);
sleep 2000
loop2:
sleep 1000
$loop_count = $loop_count + 1
if $loop_count == 20 then
return -1
endi
sql select * from streamt2;
if $rows != 1 then
print ======$rows
return -1
goto loop2
endi
if $data01 != 6 then
print ======$data01
return -1
goto loop2
endi
sql insert into t2 values(1648791233002,1,2,3,1.0);
sleep 2000
loop3:
sleep 1000
$loop_count = $loop_count + 1
if $loop_count == 20 then
return -1
endi
sql select * from streamt2;
if $rows != 0 then
print ======$rows
return -1
goto loop3
endi
sql insert into t2 values(1648791253003,1,2,3,1.0);
sleep 2000
loop4:
sleep 1000
$loop_count = $loop_count + 1
if $loop_count == 20 then
return -1
endi
sql select * from streamt2;
if $rows != 1 then
print ======$rows
return -1
goto loop4
endi
if $data01 != 8 then
print ======$data01
return -1
goto loop4
endi
sql insert into t2 values(1648791243003,1,2,3,1.0) (1648791243002,1,2,3,1.0) (1648791270004,1,2,3,1.0) (1648791280005,1,2,3,1.0) (1648791290006,1,2,3,1.0);
sleep 2000
loop5:
sleep 1000
$loop_count = $loop_count + 1
if $loop_count == 20 then
return -1
endi
sql select * from streamt2;
if $rows != 3 then
print =====rows=$rows
return -1
goto loop5
endi
if $data01 != 10 then
print ======$data01
return -1
goto loop5
endi
if $data11 != 1 then
print ======$data11
return -1
goto loop5
endi
if $data21 != 1 then
print ======$data21
return -1
goto loop5
endi
system sh/exec.sh -n dnode1 -s stop -x SIGINT
\ No newline at end of file
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录