Commit 8e527be5 authored by vipwzw's avatar vipwzw

auto ci

parent bf9bfa8b
...@@ -6,7 +6,6 @@ UNIT_HTTP="" ...@@ -6,7 +6,6 @@ UNIT_HTTP=""
source ../dapp-test-common.sh source ../dapp-test-common.sh
paracross_GetBlock2MainInfo() { paracross_GetBlock2MainInfo() {
local height local height
...@@ -40,7 +39,7 @@ function paracross_SignAndSend() { ...@@ -40,7 +39,7 @@ function paracross_SignAndSend() {
signedTx=$(curl -ksd '{"method":"Chain33.SignRawTx","params":[{"expire":"120s","fee":'"$1"',"privkey":"'"$2"'","txHex":"'"$3"'"}]}' ${UNIT_HTTP} | jq -r ".result") signedTx=$(curl -ksd '{"method":"Chain33.SignRawTx","params":[{"expire":"120s","fee":'"$1"',"privkey":"'"$2"'","txHex":"'"$3"'"}]}' ${UNIT_HTTP} | jq -r ".result")
#echo "signedTx:$signedTx" #echo "signedTx:$signedTx"
sendedTx=$(curl -ksd '{"method":"Chain33.SendTransaction","params":[{"data":"'"$signedTx"'"}]}' ${UNIT_HTTP} | jq -r ".result" ) sendedTx=$(curl -ksd '{"method":"Chain33.SendTransaction","params":[{"data":"'"$signedTx"'"}]}' ${UNIT_HTTP} | jq -r ".result")
echo "sendedTx:$sendedTx" echo "sendedTx:$sendedTx"
} }
...@@ -56,7 +55,6 @@ function paracross_QueryBalance() { ...@@ -56,7 +55,6 @@ function paracross_QueryBalance() {
return $? return $?
} }
function paracross_Transfer_Withdraw() { function paracross_Transfer_Withdraw() {
# 计数器,资产转移操作和取钱操作都成功才算成功,也就是 counter == 2 # 计数器,资产转移操作和取钱操作都成功才算成功,也就是 counter == 2
...@@ -104,7 +102,6 @@ function paracross_Transfer_Withdraw() { ...@@ -104,7 +102,6 @@ function paracross_Transfer_Withdraw() {
chain33_SignRawTx "$tx_hash" "$privkey" ${UNIT_HTTP} chain33_SignRawTx "$tx_hash" "$privkey" ${UNIT_HTTP}
#paracross_SignAndSend $fee "$privkey" "$tx_hash" #paracross_SignAndSend $fee "$privkey" "$tx_hash"
#4 查询转移后余额状态 #4 查询转移后余额状态
local times=100 local times=100
while true; do while true; do
...@@ -133,7 +130,6 @@ function paracross_Transfer_Withdraw() { ...@@ -133,7 +130,6 @@ function paracross_Transfer_Withdraw() {
chain33_SignRawTx "$tx_hash" "$privkey" ${UNIT_HTTP} chain33_SignRawTx "$tx_hash" "$privkey" ${UNIT_HTTP}
#paracross_SignAndSend $fee "$privkey" "$tx_hash" #paracross_SignAndSend $fee "$privkey" "$tx_hash"
#6 查询取钱后余额状态 #6 查询取钱后余额状态
local times=100 local times=100
while true; do while true; do
...@@ -156,7 +152,6 @@ function paracross_Transfer_Withdraw() { ...@@ -156,7 +152,6 @@ function paracross_Transfer_Withdraw() {
fi fi
done done
[ "$count" -eq 2 ] [ "$count" -eq 2 ]
local rst=$? local rst=$?
echo_rst "$FUNCNAME" "$rst" echo_rst "$FUNCNAME" "$rst"
...@@ -263,7 +258,6 @@ function run_testcases() { ...@@ -263,7 +258,6 @@ function run_testcases() {
fi fi
} }
function main() { function main() {
UNIT_HTTP=$1 UNIT_HTTP=$1
echo "=========== # paracross rpc test =============" echo "=========== # paracross rpc test ============="
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment