From 4fc6ce57f3d3d734a1acca40a7a82554aa6cb1a4 Mon Sep 17 00:00:00 2001 From: Daniel Van Der Maden Date: Mon, 18 Nov 2019 23:53:01 -0800 Subject: [PATCH] [test/deploy] Add staking debugging tools to localnet deploy script --- test/deploy.sh | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/test/deploy.sh b/test/deploy.sh index 811dac718..395425d88 100755 --- a/test/deploy.sh +++ b/test/deploy.sh @@ -59,6 +59,17 @@ function cleanup_and_result() { [ -e $RESULT_FILE ] && cat $RESULT_FILE } +function debug_staking() { + hmy_one_dir="$(go env GOPATH)/src/github.com/harmony-one" + hmy_bin="${hmy_one_dir}/go-sdk/hmy" + keystore="${hmy_one_dir}/harmony-ops/test-automation/api-tests/LocalnetValidatorKeys" + python3 -m pip install pyhmy + python3 -m pip install requests + python3 "${hmy_one_dir}/harmony-ops/test-automation/api-tests/test.py" --keystore ${keystore} \ + --cli_path ${hmy_bin} --test_dir "${hmy_one_dir}/harmony-ops/test-automation/api-tests/tests/" \ + --rpc_endpoint_src="http://localhost:9500/" --rpc_endpoint_dst="http://localhost:9501/" --ignore_regression_test +} + trap cleanup_and_result SIGINT SIGTERM function usage { @@ -192,6 +203,7 @@ while IFS='' read -r line || [[ -n "$line" ]]; do done < $config if [ "$DOTEST" == "true" ]; then + debug_staking echo "waiting for some block rewards" sleep 60 i=1