Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
taosdata
TDengine
提交
13230df9
T
TDengine
项目概览
taosdata
/
TDengine
1 年多 前同步成功
通知
1185
Star
22016
Fork
4786
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
1
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
T
TDengine
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
1
Issue
1
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
13230df9
编写于
7月 14, 2022
作者:
S
Shengliang Guan
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
test: restore some 2.0 case
上级
bfb2900c
变更
13
隐藏空白更改
内联
并排
Showing
13 changed file
with
112 addition
and
139 deletion
+112
-139
tests/script/jenkins/basic.txt
tests/script/jenkins/basic.txt
+23
-24
tests/script/tsim/table/autocreate.sim
tests/script/tsim/table/autocreate.sim
+1
-1
tests/script/tsim/table/basic1.sim
tests/script/tsim/table/basic1.sim
+0
-17
tests/script/tsim/table/basic2.sim
tests/script/tsim/table/basic2.sim
+3
-3
tests/script/tsim/table/basic3.sim
tests/script/tsim/table/basic3.sim
+2
-2
tests/script/tsim/table/createmulti.sim
tests/script/tsim/table/createmulti.sim
+1
-1
tests/script/tsim/table/date.sim
tests/script/tsim/table/date.sim
+8
-8
tests/script/tsim/table/int.sim
tests/script/tsim/table/int.sim
+23
-27
tests/script/tsim/table/limit.sim
tests/script/tsim/table/limit.sim
+2
-2
tests/script/tsim/table/smallint.sim
tests/script/tsim/table/smallint.sim
+18
-20
tests/script/tsim/table/table.sim
tests/script/tsim/table/table.sim
+2
-3
tests/script/tsim/table/tinyint.sim
tests/script/tsim/table/tinyint.sim
+17
-19
tests/script/tsim/table/vgroup.sim
tests/script/tsim/table/vgroup.sim
+12
-12
未找到文件。
tests/script/jenkins/basic.txt
浏览文件 @
13230df9
...
...
@@ -103,34 +103,33 @@
./test.sh -f tsim/show/basic.sim
# ---- table
#
./test.sh -f tsim/table/autocreate.sim
./test.sh -f tsim/table/autocreate.sim
./test.sh -f tsim/table/basic1.sim
#
./test.sh -f tsim/table/basic2.sim
#
./test.sh -f tsim/table/basic3.sim
#
./test.sh -f tsim/table/bigint.sim
#
./test.sh -f tsim/table/binary.sim
#
./test.sh -f tsim/table/bool.sim
#
./test.sh -f tsim/table/column_name.sim
#
./test.sh -f tsim/table/column_num.sim
#
./test.sh -f tsim/table/column_value.sim
#
./test.sh -f tsim/table/column2.sim
#
./test.sh -f tsim/table/createmulti.sim
#
./test.sh -f tsim/table/date.sim
#
./test.sh -f tsim/table/db.table.sim
./test.sh -f tsim/table/basic2.sim
./test.sh -f tsim/table/basic3.sim
./test.sh -f tsim/table/bigint.sim
./test.sh -f tsim/table/binary.sim
./test.sh -f tsim/table/bool.sim
./test.sh -f tsim/table/column_name.sim
./test.sh -f tsim/table/column_num.sim
./test.sh -f tsim/table/column_value.sim
./test.sh -f tsim/table/column2.sim
./test.sh -f tsim/table/createmulti.sim
./test.sh -f tsim/table/date.sim
./test.sh -f tsim/table/db.table.sim
# ./test.sh -f tsim/table/delete_reuse1.sim
# ./test.sh -f tsim/table/delete_reuse2.sim
# ./test.sh -f tsim/table/delete_writing.sim
# ./test.sh -f tsim/table/describe.sim
# ./test.sh -f tsim/table/double.sim
# ./test.sh -f tsim/table/fill.sim
# ./test.sh -f tsim/table/float.sim
# ./test.sh -f tsim/table/int.sim
# ./test.sh -f tsim/table/limit.sim
# ./test.sh -f tsim/table/smallint.sim
# ./test.sh -f tsim/table/table_len.sim
# ./test.sh -f tsim/table/table.sim
# ./test.sh -f tsim/table/tinyint.sim
# ./test.sh -f tsim/table/vgroup.sim
./test.sh -f tsim/table/describe.sim
./test.sh -f tsim/table/double.sim
./test.sh -f tsim/table/float.sim
./test.sh -f tsim/table/int.sim
./test.sh -f tsim/table/limit.sim
./test.sh -f tsim/table/smallint.sim
./test.sh -f tsim/table/table_len.sim
./test.sh -f tsim/table/table.sim
./test.sh -f tsim/table/tinyint.sim
./test.sh -f tsim/table/vgroup.sim
# ---- stream
./test.sh -f tsim/stream/basic0.sim
...
...
tests/script/tsim/table/autocreate.sim
浏览文件 @
13230df9
...
...
@@ -6,7 +6,7 @@ sql connect
print =============== create database
sql create database db
sql show databases
if $rows !=
1
then
if $rows !=
3
then
return -1
endi
...
...
tests/script/tsim/table/basic1.sim
浏览文件 @
13230df9
...
...
@@ -213,23 +213,6 @@ endi
system sh/exec.sh -n dnode1 -s stop -x SIGINT
system sh/exec.sh -n dnode1 -s start
$loop_cnt = 0
check_dnode_ready:
$loop_cnt = $loop_cnt + 1
sleep 200
if $loop_cnt == 10 then
print ====> dnode not ready!
return -1
endi
sql show dnodes
print ===> $rows $data00 $data01 $data02 $data03 $data04 $data05
if $data00 != 1 then
return -1
endi
if $data04 != ready then
goto check_dnode_ready
endi
print =============== query data
sql select * from c1
print rows: $rows
...
...
tests/script/tsim/table/basic2.sim
浏览文件 @
13230df9
...
...
@@ -20,11 +20,11 @@ endi
print =============== show
sql show databases
if $data
0
2 != 2 then
if $data
2
2 != 2 then
return -1
endi
if $data
03
!= 1 then
if $data
24
!= 1 then
return -1
endi
...
...
@@ -33,7 +33,7 @@ if $data00 != 2 then
return -1
endi
if $data01 !=
2
then
if $data01 !=
d1
then
return -1
endi
...
...
tests/script/tsim/table/basic3.sim
浏览文件 @
13230df9
...
...
@@ -6,7 +6,7 @@ sql connect
print =============== create database
sql create database db
sql show databases
if $rows !=
1
then
if $rows !=
3
then
return -1
endi
...
...
@@ -72,7 +72,7 @@ endi
print =============== drop stable
sql drop table db.st
sql show db.stables
if $rows !=
2
then
if $rows !=
0
then
return -1
endi
...
...
tests/script/tsim/table/createmulti.sim
浏览文件 @
13230df9
...
...
@@ -6,7 +6,7 @@ sql connect
print =============== create database
sql create database db
sql show databases
if $rows !=
1
then
if $rows !=
3
then
return -1
endi
...
...
tests/script/tsim/table/date.sim
浏览文件 @
13230df9
...
...
@@ -24,18 +24,18 @@ if $data00 != @17-01-01 08:00:00.001@ then
endi
print =============== step2
sql insert into $tb values ('2017-08-28 00:23:46.429+ 1a', 2)
#sql
insert into $tb values ('2017-08-28 00:23:46cd .429', 2)
sql
_error
insert into $tb values ('2017-08-28 00:23:46.429+ 1a', 2)
sql_error
insert into $tb values ('2017-08-28 00:23:46cd .429', 2)
sql select ts from $tb
if $rows !=
2
then
if $rows !=
1
then
return -1
endi
print =============== step3
#sql
insert into $tb values ('1970-01-01 08:00:00.000', 3)
#sql
insert into $tb values ('1970-01-01 08:00:00.000', 3)
sql_error
insert into $tb values ('1970-01-01 08:00:00.000', 3)
sql_error
insert into $tb values ('1970-01-01 08:00:00.000', 3)
sql select ts from $tb
if $rows !=
2
then
if $rows !=
1
then
return -1
endi
...
...
@@ -54,7 +54,7 @@ print =============== step5
sql_error insert into $tb values ('9999-12-31 213:59:59.999', 13)
sql select ts from $tb
print $rows
if $rows !=
8
then
if $rows !=
7
then
return -1
endi
...
...
@@ -62,7 +62,7 @@ print =============== step6
sql_error insert into $tb values ('9999-12-99 23:59:59.999', 13)
sql select ts from $tb
if $rows !=
8
then
if $rows !=
7
then
return -1
endi
...
...
tests/script/tsim/table/int.sim
浏览文件 @
13230df9
...
...
@@ -24,12 +24,10 @@ if $data01 != NULL then
endi
print =============== step2
sql insert into $tb values (now+1m, -2147483648) -x step2
return -1
step2:
sql insert into $tb values (now+1m, NULL)
sql insert into $tb values (now+1m, -2147483648)
sql insert into $tb values (now+2m, NULL)
sql select * from $tb order by ts desc
if $rows !=
2
then
if $rows !=
3
then
return -1
endi
if $data01 != NULL then
...
...
@@ -37,9 +35,9 @@ if $data01 != NULL then
endi
print =============== step3
sql insert into $tb values (now+
2
m, 2147483647)
sql insert into $tb values (now+
3
m, 2147483647)
sql select * from $tb order by ts desc
if $rows !=
3
then
if $rows !=
4
then
return -1
endi
if $data01 != 2147483647 then
...
...
@@ -47,12 +45,10 @@ if $data01 != 2147483647 then
endi
print =============== step4
sql insert into $tb values (now+3m, 2147483648) -x step4
return -1
step4:
sql insert into $tb values (now+3m, NULL)
sql_error insert into $tb values (now+4m, 2147483648)
sql insert into $tb values (now+5m, NULL)
sql select * from $tb order by ts desc
if $rows !=
4
then
if $rows !=
5
then
return -1
endi
if $data01 != NULL then
...
...
@@ -60,10 +56,10 @@ if $data01 != NULL then
endi
print =============== step5
sql_error insert into $tb values (now+
4
m, a2)
sql insert into $tb values (now+
4
m, 0)
sql_error insert into $tb values (now+
6
m, a2)
sql insert into $tb values (now+
7
m, 0)
sql select * from $tb order by ts desc
if $rows !=
5
then
if $rows !=
6
then
return -1
endi
if $data01 != 0 then
...
...
@@ -71,10 +67,10 @@ if $data01 != 0 then
endi
print =============== step6
sql_error insert into $tb values (now+
5
m, 2a)
sql insert into $tb values (now+
5
m, 2)
sql_error insert into $tb values (now+
8
m, 2a)
sql insert into $tb values (now+
9
m, 2)
sql select * from $tb order by ts desc
if $rows !=
6
then
if $rows !=
7
then
return -1
endi
if $data01 != 2 then
...
...
@@ -82,10 +78,10 @@ if $data01 != 2 then
endi
print =============== step7
sql_error insert into $tb values (now+
6
m, 2a'1)
sql insert into $tb values (now+
6
m, 2)
sql_error insert into $tb values (now+
10
m, 2a'1)
sql insert into $tb values (now+
11
m, 2)
sql select * from $tb order by ts desc
if $rows !=
7
then
if $rows !=
8
then
return -1
endi
if $data01 != 2 then
...
...
@@ -93,9 +89,9 @@ if $data01 != 2 then
endi
print =============== step8
sql insert into $tb values (now+
8
m, "NULL")
sql insert into $tb values (now+
12
m, "NULL")
sql select * from $tb order by ts desc
if $rows !=
8
then
if $rows !=
9
then
return -1
endi
if $data01 != NULL then
...
...
@@ -103,9 +99,9 @@ if $data01 != NULL then
endi
print =============== step9
sql insert into $tb values (now+
9
m, 'NULL')
sql insert into $tb values (now+
13
m, 'NULL')
sql select * from $tb order by ts desc
if $rows !=
9
then
if $rows !=
10
then
return -1
endi
if $data01 != NULL then
...
...
@@ -113,9 +109,9 @@ if $data01 != NULL then
endi
print =============== step10
sql insert into $tb values (now+1
0
m, -123)
sql insert into $tb values (now+1
4
m, -123)
sql select * from $tb order by ts desc
if $rows != 1
0
then
if $rows != 1
1
then
return -1
endi
if $data01 != -123 then
...
...
tests/script/tsim/table/limit.sim
浏览文件 @
13230df9
...
...
@@ -12,10 +12,10 @@ $db = $dbPrefix . $i
$tb = $tbPrefix . $i
print =================== step 0
sql create database $db
sql create database $db
vgroups 8
sql use $db
sql show vgroups
if $rows !=
0
then
if $rows !=
8
then
return -1
endi
...
...
tests/script/tsim/table/smallint.sim
浏览文件 @
13230df9
...
...
@@ -25,12 +25,10 @@ if $data01 != NULL then
endi
print =============== step2
sql insert into $tb values (now+1m, -32768) -x step2
return -1
step2:
sql insert into $tb values (now+1m, NULL)
sql insert into $tb values (now+1m, -32768)
sql insert into $tb values (now+2m, NULL)
sql select * from $tb order by ts desc
if $rows !=
2
then
if $rows !=
3
then
return -1
endi
if $data01 != NULL then
...
...
@@ -38,9 +36,9 @@ if $data01 != NULL then
endi
print =============== step3
sql insert into $tb values (now+
2
m, 32767)
sql insert into $tb values (now+
3
m, 32767)
sql select * from $tb order by ts desc
if $rows !=
3
then
if $rows !=
4
then
return -1
endi
if $data01 != 32767 then
...
...
@@ -48,12 +46,12 @@ if $data01 != 32767 then
endi
print =============== step4
sql insert into $tb values (now+
3
m, 32768) -x step4
sql insert into $tb values (now+
4
m, 32768) -x step4
return -1
step4:
sql insert into $tb values (now+
3
m, NULL)
sql insert into $tb values (now+
5
m, NULL)
sql select * from $tb order by ts desc
if $rows !=
4
then
if $rows !=
5
then
return -1
endi
if $data01 != NULL then
...
...
@@ -61,10 +59,10 @@ if $data01 != NULL then
endi
print =============== step5
sql_error insert into $tb values (now+
4
m, a2)
sql insert into $tb values (now+
4
m, 0)
sql_error insert into $tb values (now+
6
m, a2)
sql insert into $tb values (now+
7
m, 0)
sql select * from $tb order by ts desc
if $rows !=
5
then
if $rows !=
6
then
return -1
endi
if $data01 != 0 then
...
...
@@ -72,10 +70,10 @@ if $data01 != 0 then
endi
print =============== step6
sql_error insert into $tb values (now+
5
m, 2a)
sql insert into $tb values (now+
5
m, 2)
sql_error insert into $tb values (now+
8
m, 2a)
sql insert into $tb values (now+
9
m, 2)
sql select * from $tb order by ts desc
if $rows !=
6
then
if $rows !=
7
then
return -1
endi
if $data01 != 2 then
...
...
@@ -83,16 +81,16 @@ if $data01 != 2 then
endi
print =============== step7
sql_error insert into $tb values (now+
6
m, 2a'1)
sql insert into $tb values (now+
6
m, 2)
sql_error insert into $tb values (now+
10
m, 2a'1)
sql insert into $tb values (now+
11
m, 2)
sql select * from $tb order by ts desc
if $rows !=
7
then
if $rows !=
8
then
return -1
endi
if $data01 != 2 then
return -1
endi
return
sql drop database $db
sql show databases
if $rows != 2 then
...
...
tests/script/tsim/table/table.sim
浏览文件 @
13230df9
...
...
@@ -197,16 +197,15 @@ if $data01 != 7 then
endi
print =============== step10
$i = 1
$tb = $tbPrefix . $i
sql create table $tb (ts timestamp, val tinyint, val2 tinyint)
sql
_error
create table $tb (ts timestamp, val tinyint, val2 tinyint)
sql show tables
if $rows != 7 then
return -1
endi
print =============== step11
sql create table $tb (ts timestamp, val float, val2 double)
sql
_error
create table $tb (ts timestamp, val float, val2 double)
sql show tables
if $rows != 7 then
return -1
...
...
tests/script/tsim/table/tinyint.sim
浏览文件 @
13230df9
...
...
@@ -24,12 +24,10 @@ if $data01 != NULL then
endi
print =============== step2
sql insert into $tb values (now+1m, -128) -x step2
return -1
step2:
sql insert into $tb values (now+1m, NULL)
sql insert into $tb values (now+1m, -128)
sql insert into $tb values (now+2m, NULL)
sql select * from $tb order by ts desc
if $rows !=
2
then
if $rows !=
3
then
return -1
endi
if $data01 != NULL then
...
...
@@ -37,9 +35,9 @@ if $data01 != NULL then
endi
print =============== step3
sql insert into $tb values (now+
2
m, 127)
sql insert into $tb values (now+
3
m, 127)
sql select * from $tb order by ts desc
if $rows !=
3
then
if $rows !=
4
then
return -1
endi
if $data01 != 127 then
...
...
@@ -47,12 +45,12 @@ if $data01 != 127 then
endi
print =============== step4
sql insert into $tb values (now+
3
m, 128) -x step4
sql insert into $tb values (now+
4
m, 128) -x step4
return -1
step4:
sql insert into $tb values (now+
3
m, NULL)
sql insert into $tb values (now+
5
m, NULL)
sql select * from $tb
if $rows !=
4
then
if $rows !=
5
then
return -1
endi
if $data01 != NULL then
...
...
@@ -60,10 +58,10 @@ if $data01 != NULL then
endi
print =============== step5
sql_error insert into $tb values (now+
4
m, a2)
sql insert into $tb values (now+
4
m, 0)
sql_error insert into $tb values (now+
6
m, a2)
sql insert into $tb values (now+
7
m, 0)
sql select * from $tb order by ts desc
if $rows !=
5
then
if $rows !=
6
then
return -1
endi
if $data01 != 0 then
...
...
@@ -71,10 +69,10 @@ if $data01 != 0 then
endi
print =============== step6
sql_error insert into $tb values (now+
5
m, 2a)
sql insert into $tb values (now+
5
m, 2)
sql_error insert into $tb values (now+
8
m, 2a)
sql insert into $tb values (now+
9
m, 2)
sql select * from $tb order by ts desc
if $rows !=
6
then
if $rows !=
7
then
return -1
endi
if $data01 != 2 then
...
...
@@ -82,10 +80,10 @@ if $data01 != 2 then
endi
print =============== step7
sql_error insert into $tb values (now+
6
m, 2a'1)
sql insert into $tb values (now+
6
m, 2)
sql_error insert into $tb values (now+
10
m, 2a'1)
sql insert into $tb values (now+
11
m, 2)
sql select * from $tb order by ts desc
if $rows !=
7
then
if $rows !=
8
then
return -1
endi
if $data01 != 2 then
...
...
tests/script/tsim/table/vgroup.sim
浏览文件 @
13230df9
...
...
@@ -12,10 +12,10 @@ $db = $dbPrefix . $i
$tb = $tbPrefix . $i
print =================== step 1
sql create database $db
sql create database $db
vgroups 4
sql use $db
sql show vgroups
if $rows !=
0
then
if $rows !=
4
then
return -1
endi
...
...
@@ -24,7 +24,7 @@ sql create table table2 (ts timestamp, speed int)
sql create table table3 (ts timestamp, speed int)
sql create table table4 (ts timestamp, speed int)
sql show vgroups
if $rows !=
1
then
if $rows !=
4
then
return -1
endi
...
...
@@ -33,7 +33,7 @@ sql create table table6 (ts timestamp, speed int)
sql create table table7 (ts timestamp, speed int)
sql create table table8 (ts timestamp, speed int)
sql show vgroups
if $rows !=
2
then
if $rows !=
4
then
return -1
endi
...
...
@@ -42,7 +42,7 @@ sql create table table10 (ts timestamp, speed int)
sql create table table11 (ts timestamp, speed int)
sql create table table12 (ts timestamp, speed int)
sql show vgroups
if $rows !=
3
then
if $rows !=
4
then
return -1
endi
...
...
@@ -54,7 +54,7 @@ endi
sql drop table table13
sql show vgroups
if $rows !=
3
then
if $rows !=
4
then
return -1
endi
...
...
@@ -68,10 +68,10 @@ print =================== step 2
$i = 1
$db = $dbPrefix . $i
sql create database $db
sql create database $db
vgroups 2
sql use $db
sql show vgroups
if $rows !=
0
then
if $rows !=
2
then
return -1
endi
...
...
@@ -84,13 +84,13 @@ $db = $dbPrefix . $i
sql use $db
sql create table table2 (ts timestamp, speed int)
sql show vgroups
if $rows !=
1
then
if $rows !=
2
then
return -1
endi
sql drop table table2
sql show vgroups
if $rows !=
0
then
if $rows !=
2
then
return -1
endi
...
...
@@ -100,7 +100,7 @@ sql create table table3 (ts timestamp, speed int)
sql create table table4 (ts timestamp, speed int)
sql drop table table1
sql show vgroups
if $rows !=
1
then
if $rows !=
2
then
return -1
endi
...
...
@@ -129,7 +129,7 @@ sql create database $db
sql use $db
sql show databases
if $rows !=
5
then
if $rows !=
7
then
return -1
endi
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录