未验证 提交 7d9aef52 编写于 作者: H huili 提交者: GitHub

Merge pull request #5457 from taosdata/test/jenkins

[TD-3326]<test>backup taos after taos coredump
......@@ -42,15 +42,15 @@ def pre_test(){
cd ${WKC}
git checkout develop
git reset --hard HEAD~10 >/dev/null
git pull
git pull >/dev/null
git fetch origin +refs/pull/${CHANGE_ID}/merge
git checkout -qf FETCH_HEAD
git --no-pager diff --name-only FETCH_HEAD $(git merge-base FETCH_HEAD develop)|grep -v -E '.*md|//src//connector|Jenkinsfile' || exit 0
git --no-pager diff --name-only FETCH_HEAD $(git merge-base FETCH_HEAD develop)|grep -v -E '.*md|//src//connector|Jenkinsfile'
find ${WKC}/tests/pytest -name \'*\'.sql -exec rm -rf {} \\;
cd ${WK}
git reset --hard HEAD~10
git checkout develop
git pull
git checkout develop
git pull >/dev/null
cd ${WK}
export TZ=Asia/Harbin
date
......
......@@ -24,11 +24,16 @@ function stopTaosd {
function dohavecore(){
corefile=`find $corepath -mmin 1`
core_file=`echo $corefile|cut -d " " -f2`
echo $core_file
proc=`echo $corefile|cut -d "_" -f3`
if [ -n "$corefile" ];then
echo 'taosd or taos has generated core'
if [[ $1 == 1 ]];then
exit 8
fi
echo 'taosd or taos has generated core'
tar -zcvPf $corepath'taos_'`date "+%Y_%m_%d_%H_%M_%S"`.tar.gz /usr/local/taos/
if [[ $1 == 1 ]];then
echo '\n'|gdb /usr/local/taos/bin/$proc $core_file -ex "bt 10" -ex quit
exit 8
fi
fi
}
function runSimCaseOneByOne {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册