Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
taosdata
TDengine
提交
bab7abea
T
TDengine
项目概览
taosdata
/
TDengine
11 个月 前同步成功
通知
1179
Star
22014
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看板
体验新版 GitCode,发现更多精彩内容 >>
提交
bab7abea
编写于
7月 21, 2022
作者:
S
Shengliang Guan
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
test: restore 2.0 case
上级
9f3e7f02
变更
8
隐藏空白更改
内联
并排
Showing
8 changed file
with
16 addition
and
55 deletion
+16
-55
tests/script/jenkins/basic.txt
tests/script/jenkins/basic.txt
+8
-8
tests/script/tsim/parser/constCol.sim
tests/script/tsim/parser/constCol.sim
+4
-14
tests/script/tsim/parser/import.sim
tests/script/tsim/parser/import.sim
+0
-7
tests/script/tsim/parser/import_commit1.sim
tests/script/tsim/parser/import_commit1.sim
+1
-3
tests/script/tsim/parser/import_commit2.sim
tests/script/tsim/parser/import_commit2.sim
+1
-3
tests/script/tsim/parser/import_commit3.sim
tests/script/tsim/parser/import_commit3.sim
+1
-5
tests/script/tsim/parser/insert_tb.sim
tests/script/tsim/parser/insert_tb.sim
+0
-2
tests/script/tsim/parser/tbnameIn_query.sim
tests/script/tsim/parser/tbnameIn_query.sim
+1
-13
未找到文件。
tests/script/jenkins/basic.txt
浏览文件 @
bab7abea
...
...
@@ -96,7 +96,7 @@
# jira ./test.sh -f tsim/parser/columnValue.sim
./test.sh -f tsim/parser/commit.sim
# jira ./test.sh -f tsim/parser/condition.sim
##
./test.sh -f tsim/parser/constCol.sim
./test.sh -f tsim/parser/constCol.sim
./test.sh -f tsim/parser/create_db.sim
./test.sh -f tsim/parser/create_mt.sim
# jira ./test.sh -f tsim/parser/create_tb_with_tag_name.sim
...
...
@@ -113,11 +113,11 @@
# ./test.sh -f tsim/parser/groupby.sim
# ./test.sh -f tsim/parser/having_child.sim
## ./test.sh -f tsim/parser/having.sim
## ./test.sh -f tsim/parser/import
.sim
# ./test.sh -f tsim/parser/import_commit1
.sim
# ./test.sh -f tsim/parser/import_commit2
.sim
#
./test.sh -f tsim/parser/import_commit3
.sim
## ./test.sh -f tsim/parser/import_file
.sim
./test.sh -f tsim/parser/import_commit1
.sim
./test.sh -f tsim/parser/import_commit2
.sim
./test.sh -f tsim/parser/import_commit3
.sim
#
jira ./test.sh -f tsim/parser/import_file
.sim
./test.sh -f tsim/parser/import
.sim
## ./test.sh -f tsim/parser/insert_multiTbl.sim
# ./test.sh -f tsim/parser/insert_tb.sim
## ./test.sh -f tsim/parser/interp.sim
...
...
@@ -159,7 +159,7 @@
./test.sh -f tsim/parser/stableOp.sim
# ./test.sh -f tsim/parser/tags_dynamically_specifiy.sim
# ./test.sh -f tsim/parser/tags_filter.sim
# jira
./test.sh -f tsim/parser/tbnameIn.sim
./test.sh -f tsim/parser/tbnameIn.sim
./test.sh -f tsim/parser/timestamp.sim
./test.sh -f tsim/parser/top_groupby.sim
./test.sh -f tsim/parser/topbot.sim
...
...
@@ -328,7 +328,7 @@
./test.sh -f tsim/vnode/stable_replica3_vnode3.sim
# --- sync
./test.sh -f tsim/sync/3Replica1VgElect.sim
# jira
./test.sh -f tsim/sync/3Replica1VgElect.sim
./test.sh -f tsim/sync/3Replica5VgElect.sim
./test.sh -f tsim/sync/oneReplica1VgElect.sim
./test.sh -f tsim/sync/oneReplica5VgElect.sim
...
...
tests/script/tsim/parser/constCol.sim
浏览文件 @
bab7abea
...
...
@@ -8,20 +8,16 @@ sql use db;
sql create table t (ts timestamp, i int);
sql create table st1 (ts timestamp, f1 int) tags(t1 int);
sql create table st2 (ts timestamp, f2 int) tags(t2 int);
sql create table t1 using st1 tags(1);
sql create table t2 using st2 tags(1);
sql insert into t1 values(1575880055000, 1);
sql insert into t1 values(1575880059000, 1);
sql insert into t1 values(1575880069000, 1);
sql insert into t2 values(1575880055000, 2);
sql select st1.ts, st1.f1, st2.f2 from db.st1, db.st2 where st1.t1=st2.t2 and st1.ts=st2.ts
system_content curl -H 'Authorization: Taosd /KfeAzX/f9na8qdtNZmtONryp201ma04bEl8LcvLUd7a8qdtNZmtONryp201ma04' -d 'select st1.ts, st1.f1, st2.f2 from db.st1, db.st2 where st1.t1=st2.t2 and st1.ts=st2.ts' 127.0.0.1:7111/restful/sql
print ==============select with user-defined columns
sql select 'abc' as f, ts,f1 from t1
if $rows != 3 then
...
...
@@ -301,13 +297,13 @@ if $data04 != 1.982700000 then
endi
print ======================udc with interval
sql select count(*), 'uuu' from t1 interval(1s)
order by ts desc
;
sql select count(*), 'uuu' from t1 interval(1s);
if $rows != 3 then
return -1
endi
print ======================udc with tags
sql select t1,'abc',tbname from st1
sql select
distinct
t1,'abc',tbname from st1
if $rows != 1 then
return -1
endi
...
...
@@ -343,31 +339,26 @@ if $rows != 0 then
return -1
endi
print ======================udc with normal column group by
sql_error select from t1
sql_error select abc from t1
sql_error select abc as tu from t1
print ========================> td-1756
sql
_error
select * from t1 where ts>now-1y
sql
_error
select * from t1 where ts>now-1n
sql select * from t1 where ts>now-1y
sql select * from t1 where ts>now-1n
print ========================> td-1752
sql select * from db.st2 where t2 < 200 and t2 is not null;
if $rows != 1 then
return -1
endi
if $data00 != @19-12-09 16:27:35.000@ then
return -1
endi
if $data01 != 2 then
return -1
endi
if $data02 != 1 then
return -1
endi
...
...
@@ -376,7 +367,6 @@ sql select * from db.st2 where t2 > 200 or t2 is null;
if $rows != 0 then
return -1
endi
sql select * from st2 where t2 < 200 and t2 is null;
if $rows != 0 then
return -1
...
...
tests/script/tsim/parser/import.sim
浏览文件 @
bab7abea
...
...
@@ -22,15 +22,10 @@ sql use $db
sql create table tb (ts timestamp, c1 int, c2 timestamp)
sql insert into tb values ('2019-05-05 11:30:00.000', 1, now)
sql insert into tb values ('2019-05-05 12:00:00.000', 1, now)
sleep 500
sql import into tb values ('2019-05-05 11:00:00.000', -1, now)
sleep 500
sql import into tb values ('2019-05-05 11:59:00.000', -1, now)
sleep 500
sql import into tb values ('2019-05-04 08:00:00.000', -1, now)
sleep 500
sql import into tb values ('2019-05-04 07:59:00.000', -1, now)
sleep 500
sql select * from tb
if $rows != 6 then
...
...
@@ -57,11 +52,9 @@ endi
print ================== restart server to commit data into disk
system sh/exec.sh -n dnode1 -s stop -x SIGINT
sleep 500
system sh/exec.sh -n dnode1 -s start
print ================== server restart completed
sql connect
sleep 100
sql use $db
sql select * from tb
...
...
tests/script/tsim/parser/import_commit1.sim
浏览文件 @
bab7abea
...
...
@@ -19,7 +19,7 @@ $stb = $stbPrefix . $i
sql drop database $db -x step1
step1:
sql create database $db
cache 16
sql create database $db
print ====== create tables
sql use $db
...
...
@@ -36,8 +36,6 @@ while $x < $rowNum
endw
print ====== tables created
sleep 500
$ts = $ts0 + $delta
$ts = $ts + 1
sql import into $tb values ( $ts , -1)
...
...
tests/script/tsim/parser/import_commit2.sim
浏览文件 @
bab7abea
...
...
@@ -18,7 +18,7 @@ $stb = $stbPrefix . $i
sql drop database $db -x step1
step1:
sql create database $db
cache 16
sql create database $db
print ====== create tables
sql use $db
...
...
@@ -35,8 +35,6 @@ while $x < $rowNum
endw
print ====== tables created
sleep 500
$ts = $ts0 + $delta
$ts = $ts + 1
sql import into $tb values ( $ts , -1)
...
...
tests/script/tsim/parser/import_commit3.sim
浏览文件 @
bab7abea
...
...
@@ -18,7 +18,7 @@ $stb = $stbPrefix . $i
sql drop database $db -x step1
step1:
sql create database $db
cache 16
sql create database $db
print ====== create tables
sql use $db
sql reset query cache
...
...
@@ -35,16 +35,12 @@ while $x < $rowNum
endw
print ====== tables created
sleep 500
$ts = $ts + 1
sql insert into $tb values ( $ts , -1, -1, -1, -1, -1)
$ts = $ts0 + $delta
$ts = $ts + 1
sql import into $tb values ( $ts , -2, -2, -2, -2, -2)
sleep 500
sql show databases
sql select count(*) from $tb
...
...
tests/script/tsim/parser/insert_tb.sim
浏览文件 @
bab7abea
...
...
@@ -99,7 +99,6 @@ if $rows != 1 then
endi
sql drop database $db
sleep 100
sql create database $db
sql use $db
sql create table stb1 (ts timestamp, c1 int) tags(t1 int)
...
...
@@ -132,7 +131,6 @@ if $data21 != 1.000000000 then
endi
sql drop database $db
sleep 100
sql create database $db
sql use $db
sql create table stb (ts timestamp, c1 int, c2 bigint, c3 float, c4 double, c5 nchar(10), c6 binary(20)) tags(t1 int, t2 bigint, t3 double, t4 float, t5 nchar(10))
...
...
tests/script/tsim/parser/tbnameIn_query.sim
浏览文件 @
bab7abea
...
...
@@ -104,7 +104,7 @@ endi
## tbname in can accpet Upper case table name
print select count(*), t1 from $stb where tbname in ('ti_tb0', 'TI_tb1', 'TI_TB2') group by t1 order by t1
sql select count(*), t1 from $stb where tbname in ('ti_tb0', 'TI_tb1', 'TI_TB2') group by t1 order by t1
if $rows !=
3
then
if $rows !=
1
then
return -1
endi
if $data00 != 10 then
...
...
@@ -113,18 +113,6 @@ endi
if $data01 != 0 then
return -1
endi
if $data10 != 10 then
return -1
endi
if $data11 != 1 then
return -1
endi
if $data20 != 10 then
return -1
endi
if $data21 != 2 then
return -1
endi
# multiple tbname in is not allowed NOW
sql select count(*), t1 from $stb where tbname in ('ti_tb1', 'ti_tb300') and tbname in ('ti_tb5', 'ti_tb1000') group by t1 order by t1 asc
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录