From 2cf19c866c2a988fc02ec74270a7c3c1f4322dde Mon Sep 17 00:00:00 2001 From: liuyq-617 Date: Mon, 16 Aug 2021 15:51:36 +0800 Subject: [PATCH 1/4] [TD-6035]add connector test in CI --- Jenkinsfile | 23 +++++++++++++++++++++++ tests/pytest/fulltest.sh | 5 ----- 2 files changed, 23 insertions(+), 5 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index b073c32e13..39ff596c2e 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -224,6 +224,29 @@ pipeline { steps { timeout(time: 55, unit: 'MINUTES'){ pre_test() + sh ''' + rm -rf /var/lib/taos/* + rm -rf /var/log/taos/* + nohup taosd >/dev/null + sleep 10 + ''' + sh ''' + cd ${WKC}/tests/examples/nodejs + git clean -dfx + npm install td2.0-connector + node nodejsChecker.js host=localhost + ''' + sh ''' + cd ${WKC}/tests/examples/C#/taosdemo + git clean -dfx + mcs -out:taosdemo *.cs + ./taosdemo + ''' + sh ''' + cd ${WKC}/tests/gotest + git clean -dfx + bash batchtest.sh + ''' sh ''' cd ${WKC}/tests ./test-all.sh b1fq diff --git a/tests/pytest/fulltest.sh b/tests/pytest/fulltest.sh index 4ea9d9d495..9546ea1402 100755 --- a/tests/pytest/fulltest.sh +++ b/tests/pytest/fulltest.sh @@ -296,22 +296,17 @@ python3 ./test.py -f client/noConnectionErrorTest.py python3 testCompress.py python3 testNoCompress.py python3 testMinTablesPerVnode.py - - python3 queryCount.py python3 ./test.py -f query/queryGroupbyWithInterval.py python3 client/twoClients.py python3 test.py -f query/queryInterval.py python3 test.py -f query/queryFillTest.py - # subscribe python3 test.py -f subscribe/singlemeter.py #python3 test.py -f subscribe/stability.py python3 test.py -f subscribe/supertable.py - # topic python3 ./test.py -f topic/topicQuery.py - #======================p3-end=============== #======================p4-start=============== From 6c5288b2ebadf8dc7314355cb2cdaea095da7d81 Mon Sep 17 00:00:00 2001 From: liuyq-617 Date: Mon, 16 Aug 2021 16:16:13 +0800 Subject: [PATCH 2/4] update --- Jenkinsfile | 9 +++------ tests/pytest/fulltest.sh | 2 -- tests/test-all.sh | 2 +- 3 files changed, 4 insertions(+), 9 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 39ff596c2e..b6f9b54aa4 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -227,24 +227,21 @@ pipeline { sh ''' rm -rf /var/lib/taos/* rm -rf /var/log/taos/* - nohup taosd >/dev/null + nohup taosd >/dev/null & sleep 10 ''' sh ''' cd ${WKC}/tests/examples/nodejs - git clean -dfx - npm install td2.0-connector + npm install td2.0-connector > /dev/null 2>&1 node nodejsChecker.js host=localhost ''' sh ''' cd ${WKC}/tests/examples/C#/taosdemo - git clean -dfx mcs -out:taosdemo *.cs - ./taosdemo + echo '' |./taosdemo ''' sh ''' cd ${WKC}/tests/gotest - git clean -dfx bash batchtest.sh ''' sh ''' diff --git a/tests/pytest/fulltest.sh b/tests/pytest/fulltest.sh index 9546ea1402..d9c2fad6ad 100755 --- a/tests/pytest/fulltest.sh +++ b/tests/pytest/fulltest.sh @@ -369,8 +369,6 @@ python3 ./test.py -f insert/insert_locking.py python3 ./test.py -f alter/alter_debugFlag.py python3 ./test.py -f query/queryBetweenAnd.py python3 ./test.py -f tag_lite/alter_tag.py - - python3 test.py -f tools/taosdemoAllTest/TD-4985/query-limit-offset.py python3 test.py -f tools/taosdemoAllTest/TD-5213/insert4096columns_not_use_taosdemo.py python3 test.py -f tools/taosdemoAllTest/TD-5213/insertSigcolumnsNum4096.py diff --git a/tests/test-all.sh b/tests/test-all.sh index 8dd1ade9be..c18951b8ac 100755 --- a/tests/test-all.sh +++ b/tests/test-all.sh @@ -12,7 +12,7 @@ IN_TDINTERNAL="community" function stopTaosd { echo "Stop taosd" - sudo systemctl stop taosd + sudo systemctl stop taosd || echo 'no sudo or systemctl or stop fail' PID=`ps -ef|grep -w taosd | grep -v grep | awk '{print $2}'` while [ -n "$PID" ] do From 94beba1125169b71549bb7afebc2169985ccf5e2 Mon Sep 17 00:00:00 2001 From: liuyq-617 Date: Mon, 16 Aug 2021 16:21:21 +0800 Subject: [PATCH 3/4] update go test case --- tests/gotest/case001/case001.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/gotest/case001/case001.sh b/tests/gotest/case001/case001.sh index 831e9f83ac..b2c549f6ed 100644 --- a/tests/gotest/case001/case001.sh +++ b/tests/gotest/case001/case001.sh @@ -16,6 +16,7 @@ script_dir="$(dirname $(readlink -f $0))" cd $script_dir rm -f go.* go mod init demotest +go mod tidy go build sleep 1s ./demotest -h $1 -p $2 From 12babe9dcb2e3a2504f8437981be2a19a299fc29 Mon Sep 17 00:00:00 2001 From: liuyq-617 Date: Mon, 16 Aug 2021 16:27:36 +0800 Subject: [PATCH 4/4] update --- Jenkinsfile | 2 +- tests/gotest/case001/case001.sh | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index b6f9b54aa4..882d224407 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -237,7 +237,7 @@ pipeline { ''' sh ''' cd ${WKC}/tests/examples/C#/taosdemo - mcs -out:taosdemo *.cs + mcs -out:taosdemo *.cs > /dev/null 2>&1 echo '' |./taosdemo ''' sh ''' diff --git a/tests/gotest/case001/case001.sh b/tests/gotest/case001/case001.sh index b2c549f6ed..94e5bb44e0 100644 --- a/tests/gotest/case001/case001.sh +++ b/tests/gotest/case001/case001.sh @@ -15,8 +15,8 @@ script_dir="$(dirname $(readlink -f $0))" ###### step 3: start build cd $script_dir rm -f go.* -go mod init demotest -go mod tidy -go build +go mod init demotest > /dev/null 2>&1 +go mod tidy > /dev/null 2>&1 +go build > /dev/null 2>&1 sleep 1s ./demotest -h $1 -p $2