Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
taosdata
TDengine
提交
4dc1b334
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看板
提交
4dc1b334
编写于
11月 20, 2022
作者:
S
Shengliang Guan
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
test: python asan
上级
ed7eb1cb
变更
5
隐藏空白更改
内联
并排
Showing
5 changed file
with
25 addition
and
13 deletion
+25
-13
tests/script/sh/checkAsan.sh
tests/script/sh/checkAsan.sh
+1
-0
tests/script/sh/exec.sh
tests/script/sh/exec.sh
+1
-0
tests/script/sh/stop_dnodes.sh
tests/script/sh/stop_dnodes.sh
+1
-1
tests/system-test/test.py
tests/system-test/test.py
+1
-1
tests/system-test/test.sh
tests/system-test/test.sh
+21
-11
未找到文件。
tests/script/sh/checkAsan.sh
浏览文件 @
4dc1b334
...
...
@@ -3,6 +3,7 @@
set
+e
#set -x
export
LD_PRELOAD
=
SCRIPT_DIR
=
`
dirname
$0
`
cd
$SCRIPT_DIR
/../
SCRIPT_DIR
=
`
pwd
`
...
...
tests/script/sh/exec.sh
浏览文件 @
4dc1b334
...
...
@@ -11,6 +11,7 @@
set
+e
#set -x
export
LD_PRELOAD
=
UNAME_BIN
=
`
which
uname
`
OS_TYPE
=
`
$UNAME_BIN
`
...
...
tests/script/sh/stop_dnodes.sh
浏览文件 @
4dc1b334
...
...
@@ -3,10 +3,10 @@
set
+e
#set -x
export
LD_PRELOAD
=
UNAME_BIN
=
`
which
uname
`
OS_TYPE
=
`
$UNAME_BIN
`
export
LD_PRELOAD
=
PID
=
`
ps
-ef
|grep /usr/bin/taosd |
grep
-v
grep
|
awk
'{print $2}'
`
if
[
-n
"
$PID
"
]
;
then
echo
systemctl stop taosd
...
...
tests/system-test/test.py
浏览文件 @
4dc1b334
...
...
@@ -555,5 +555,5 @@ if __name__ == "__main__":
conn
.
close
()
if
asan
:
tdDnodes
.
StopAllSigint
()
tdLog
.
info
(
"
a
ddress sanitizer mode finished"
)
tdLog
.
info
(
"
A
ddress sanitizer mode finished"
)
sys
.
exit
(
0
)
tests/system-test/test.sh
浏览文件 @
4dc1b334
...
...
@@ -45,13 +45,11 @@ declare -x SIM_DIR=$TOP_DIR/sim
PROGRAM
=
$BUILD_DIR
/build/bin/tsim
PRG_DIR
=
$SIM_DIR
/tsim
ASAN_DIR
=
$SIM_DIR
/asan
SYSTEM_TEST_DIR
=
$CODE_DIR
/tests/system-test
chmod
-R
777
$PRG_DIR
echo
"------------------------------------------------------------------------"
echo
"Start TDengine Testing Case ..."
echo
"BUILD_DIR:
$BUILD_DIR
"
echo
"SYSTEM_TEST_DIR :
$SYSTEM_TEST_DIR
"
echo
"SIM_DIR :
$SIM_DIR
"
echo
"CODE_DIR :
$CODE_DIR
"
echo
"ASAN_DIR :
$ASAN_DIR
"
...
...
@@ -61,24 +59,36 @@ rm -rf $SIM_DIR/*
mkdir
-p
$PRG_DIR
mkdir
-p
$ASAN_DIR
cd
$
SYSTEM_TEST
_DIR
cd
$
CODE
_DIR
ulimit
-n
600000
ulimit
-c
unlimited
#sudo sysctl -w kernel.core_pattern=$TOP_DIR/core.%p.%e
echo
"ExcuteCmd:"
$*
echo
"AsanDir:"
$ASAN_DIR
/psim.info
AsanFile
=
$ASAN_DIR
/psim.asan
echo
"AsanFile:"
$AsanFile
export
LD_PRELOAD
=
libasan.so.5
$*
-a
2>
$ASAN_DIR
/psim.info
result
=
$?
echo
"Execute result:"
$result
if
[
$result
-eq
0
]
;
then
$CODE_DIR
/tests/script/sh/checkAsan.sh
$*
-a
2>
$AsanFile
export
LD_PRELOAD
=
AsanFileLen
=
`
cat
$AsanFile
|
wc
-l
`
while
[
$AsanFileLen
-lt
10
]
do
sleep
1
`
cat
$AsanFile
|
wc
-l
`
done
echo
"AsanFileLen:"
$AsanFileLen
AsanFileSuccessLen
=
`
grep
-w
successfully
$AsanFile
|
wc
-l
`
echo
"AsanFileSuccessLen:"
$AsanFileSuccessLen
if
[
$AsanFileSuccessLen
-gt
0
]
;
then
echo
"Execute script successfully and check asan"
$CODE_DIR
/../script/sh/checkAsan.sh
else
echo
"Execute script failure"
exit
1
fi
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录