From 296a9c4ff516c906c7b7b99d8d58306f55b6b4a7 Mon Sep 17 00:00:00 2001 From: Raneet Debnath Date: Fri, 18 Nov 2022 18:58:52 +0530 Subject: [PATCH] fix: incorrect condition --- integration-tests/smoke_test.sh | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/integration-tests/smoke_test.sh b/integration-tests/smoke_test.sh index d4a4ed2763..62ca370ee7 100644 --- a/integration-tests/smoke_test.sh +++ b/integration-tests/smoke_test.sh @@ -18,16 +18,20 @@ do exit 1 fi - if (( $balance > $balanceInit )) && [ $stateSyncFound != "true" ]; then - stateSyncTime=$(( SECONDS - start_time )) - stateSyncFound="true" + if (( $balance > $balanceInit )); then + if [ $stateSyncFound != "true" ]; then + stateSyncTime=$(( SECONDS - start_time )) + stateSyncFound="true" + fi fi checkpointID=$(curl -sL http://localhost:1317/checkpoints/latest | jq .result.id) - if [ $checkpointID != "null" ] && [ $checkpointFound != "true"]; then - checkpointTime=$(( SECONDS - start_time )) - checkpointFound="true" + if [ $checkpointID != "null" ]; then + if [ $checkpointFound != "true" ]; then + checkpointTime=$(( SECONDS - start_time )) + checkpointFound="true" + fi fi if [ $stateSyncFound == "true" ] && [ $checkpointFound == "true" ]; then