Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
taosdata
TDengine
提交
cd9070ff
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看板
提交
cd9070ff
编写于
3月 03, 2023
作者:
J
jiacy-jcy
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
test:update test case for show command
上级
fbeb2c07
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
15 addition
and
14 deletion
+15
-14
tests/system-test/0-others/show.py
tests/system-test/0-others/show.py
+15
-14
未找到文件。
tests/system-test/0-others/show.py
浏览文件 @
cd9070ff
...
@@ -28,8 +28,9 @@ class TDTestCase:
...
@@ -28,8 +28,9 @@ class TDTestCase:
self
.
perf_param
=
[
'apps'
,
'connections'
,
'consumers'
,
'queries'
,
'transactions'
]
self
.
perf_param
=
[
'apps'
,
'connections'
,
'consumers'
,
'queries'
,
'transactions'
]
self
.
perf_param_list
=
[
'apps'
,
'connections'
,
'consumers'
,
'queries'
,
'trans'
]
self
.
perf_param_list
=
[
'apps'
,
'connections'
,
'consumers'
,
'queries'
,
'trans'
]
self
.
dbname
=
"db"
self
.
dbname
=
"db"
self
.
stbname
=
f
'
{
self
.
dbname
}
.`
{
tdCom
.
getLongName
(
5
)
}
`'
self
.
vgroups
=
10
self
.
tbname
=
f
'
{
self
.
dbname
}
.`
{
tdCom
.
getLongName
(
3
)
}
`'
self
.
stbname
=
f
'`
{
tdCom
.
getLongName
(
5
)
}
`'
self
.
tbname
=
f
'`
{
tdCom
.
getLongName
(
3
)
}
`'
self
.
db_param
=
{
self
.
db_param
=
{
"database"
:
f
"
{
self
.
dbname
}
"
,
"database"
:
f
"
{
self
.
dbname
}
"
,
"buffer"
:
100
,
"buffer"
:
100
,
...
@@ -42,15 +43,13 @@ class TDTestCase:
...
@@ -42,15 +43,13 @@ class TDTestCase:
"pagesize"
:
16
,
"pagesize"
:
16
,
"precision"
:
"'ms'"
,
"precision"
:
"'ms'"
,
"replica"
:
1
,
"replica"
:
1
,
"retentions"
:
"15s:7d,1m:21d,15m:50d"
,
"wal_level"
:
1
,
"wal_level"
:
1
,
"wal_fsync_period"
:
6000
,
"wal_fsync_period"
:
6000
,
"wal_retention_period"
:
1
,
"wal_retention_size"
:
1024
,
"wal_roll_period"
:
0
,
"wal_roll_period"
:
0
,
"wal_segment_size"
:
1024
,
"wal_segment_size"
:
1024
,
"vgroups"
:
10
,
"vgroups"
:
self
.
vgroups
,
"stt_trigger"
:
1
"stt_trigger"
:
1
,
"tsdb_pagesize"
:
16
}
}
def
ins_check
(
self
):
def
ins_check
(
self
):
tdSql
.
prepare
()
tdSql
.
prepare
()
...
@@ -89,9 +88,10 @@ class TDTestCase:
...
@@ -89,9 +88,10 @@ class TDTestCase:
create_sql
=
'create'
create_sql
=
'create'
for
key
,
value
in
sql_dict
.
items
():
for
key
,
value
in
sql_dict
.
items
():
create_sql
+=
f
'
{
key
}
{
value
}
'
create_sql
+=
f
'
{
key
}
{
value
}
'
return
create_sql
def
show_create_sql
(
self
):
def
show_create_sql
(
self
):
create_db_sql
=
self
.
set_create_database_sql
(
self
.
db_param
)
create_db_sql
=
self
.
set_create_database_sql
(
self
.
db_param
)
print
(
create_db_sql
)
tdSql
.
execute
(
create_db_sql
)
tdSql
.
execute
(
create_db_sql
)
tdSql
.
query
(
f
'show create database
{
self
.
dbname
}
'
)
tdSql
.
query
(
f
'show create database
{
self
.
dbname
}
'
)
tdSql
.
checkEqual
(
self
.
dbname
,
tdSql
.
queryResult
[
0
][
0
])
tdSql
.
checkEqual
(
self
.
dbname
,
tdSql
.
queryResult
[
0
][
0
])
...
@@ -105,7 +105,9 @@ class TDTestCase:
...
@@ -105,7 +105,9 @@ class TDTestCase:
continue
continue
else
:
else
:
tdLog
.
exit
(
f
"show create database check failed with
{
key
}
{
value
}
"
)
tdLog
.
exit
(
f
"show create database check failed with
{
key
}
{
value
}
"
)
tdSql
.
query
(
'show vnodes 1'
)
tdSql
.
checkRows
(
self
.
vgroups
)
tdSql
.
execute
(
f
'use
{
self
.
dbname
}
'
)
column_dict
=
{
column_dict
=
{
'`ts`'
:
'timestamp'
,
'`ts`'
:
'timestamp'
,
...
@@ -186,10 +188,10 @@ class TDTestCase:
...
@@ -186,10 +188,10 @@ class TDTestCase:
tdSql
.
checkEqual
(
grants_info
,
licences_info
)
tdSql
.
checkEqual
(
grants_info
,
licences_info
)
def
run
(
self
):
def
run
(
self
):
self
.
check_gitinfo
()
#
self.check_gitinfo()
self
.
show_base
()
#
self.show_base()
self
.
ins_check
()
#
self.ins_check()
self
.
perf_check
()
#
self.perf_check()
self
.
show_create_sql
()
self
.
show_create_sql
()
def
stop
(
self
):
def
stop
(
self
):
...
@@ -198,4 +200,3 @@ class TDTestCase:
...
@@ -198,4 +200,3 @@ class TDTestCase:
tdCases
.
addWindows
(
__file__
,
TDTestCase
())
tdCases
.
addWindows
(
__file__
,
TDTestCase
())
tdCases
.
addLinux
(
__file__
,
TDTestCase
())
tdCases
.
addLinux
(
__file__
,
TDTestCase
())
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录