fixing RA test iteration when failing

This commit is contained in:
hardy
2020-12-04 13:05:42 +01:00
parent a371f5580e
commit bfeae0a0a4
+10 -9
View File
@@ -2200,7 +2200,7 @@ function run_test_on_vm {
mkdir --parents $ARCHIVES_LOC mkdir --parents $ARCHIVES_LOC
fi fi
local try_cnt="0" local try_cnt=0
NR_STATUS=0 NR_STATUS=0
######### start of RA TEST loop ######### start of RA TEST loop
@@ -2232,7 +2232,7 @@ function run_test_on_vm {
scp -o StrictHostKeyChecking=no ubuntu@$GNB_VM_IP_ADDR:/home/ubuntu/tmp/cmake_targets/log/$CURRENT_GNB_LOG_FILE $ARCHIVES_LOC scp -o StrictHostKeyChecking=no ubuntu@$GNB_VM_IP_ADDR:/home/ubuntu/tmp/cmake_targets/log/$CURRENT_GNB_LOG_FILE $ARCHIVES_LOC
scp -o StrictHostKeyChecking=no ubuntu@$NR_UE_VM_IP_ADDR:/home/ubuntu/tmp/cmake_targets/log/$CURRENT_NR_UE_LOG_FILE $ARCHIVES_LOC scp -o StrictHostKeyChecking=no ubuntu@$NR_UE_VM_IP_ADDR:/home/ubuntu/tmp/cmake_targets/log/$CURRENT_NR_UE_LOG_FILE $ARCHIVES_LOC
SYNC_STATUS=-1 SYNC_STATUS=-1
try_cnt=$[$try_cnt+1] try_cnt=$((try_cnt+1))
continue continue
fi fi
@@ -2255,9 +2255,10 @@ function run_test_on_vm {
if [ $RA_STATUS -ne 0 ] if [ $RA_STATUS -ne 0 ]
then then
echo "RA test NOT OK" echo "RA test NOT OK"
try_cnt=$[$try_cnt+1] echo "try_cnt = " $try_cnt
try_cnt=$((try_cnt+1))
else else
try_cnt=$[$try_cnt+10] try_cnt=$((try_cnt+10))
fi fi
done done
########### end RA test ########### end RA test
@@ -2266,7 +2267,7 @@ function run_test_on_vm {
######### start of PHY TEST loop ######### start of PHY TEST loop
try_cnt="0" try_cnt=0
while [ $try_cnt -lt 4 ] while [ $try_cnt -lt 4 ]
do do
@@ -2297,7 +2298,7 @@ function run_test_on_vm {
scp -o StrictHostKeyChecking=no ubuntu@$GNB_VM_IP_ADDR:/home/ubuntu/tmp/cmake_targets/log/$CURRENT_GNB_LOG_FILE $ARCHIVES_LOC scp -o StrictHostKeyChecking=no ubuntu@$GNB_VM_IP_ADDR:/home/ubuntu/tmp/cmake_targets/log/$CURRENT_GNB_LOG_FILE $ARCHIVES_LOC
scp -o StrictHostKeyChecking=no ubuntu@$NR_UE_VM_IP_ADDR:/home/ubuntu/tmp/cmake_targets/log/$CURRENT_NR_UE_LOG_FILE $ARCHIVES_LOC scp -o StrictHostKeyChecking=no ubuntu@$NR_UE_VM_IP_ADDR:/home/ubuntu/tmp/cmake_targets/log/$CURRENT_NR_UE_LOG_FILE $ARCHIVES_LOC
SYNC_STATUS=-1 SYNC_STATUS=-1
try_cnt=$[$try_cnt+1] try_cnt=$((try_cnt+1))
continue continue
fi fi
@@ -2337,7 +2338,7 @@ function run_test_on_vm {
terminate_enb_ue_basic_sim $GNB_VM_CMDS $GNB_VM_IP_ADDR 1 terminate_enb_ue_basic_sim $GNB_VM_CMDS $GNB_VM_IP_ADDR 1
scp -o StrictHostKeyChecking=no ubuntu@$GNB_VM_IP_ADDR:/home/ubuntu/tmp/cmake_targets/log/$CURRENT_GNB_LOG_FILE $ARCHIVES_LOC scp -o StrictHostKeyChecking=no ubuntu@$GNB_VM_IP_ADDR:/home/ubuntu/tmp/cmake_targets/log/$CURRENT_GNB_LOG_FILE $ARCHIVES_LOC
scp -o StrictHostKeyChecking=no ubuntu@$NR_UE_VM_IP_ADDR:/home/ubuntu/tmp/cmake_targets/log/$CURRENT_NR_UE_LOG_FILE $ARCHIVES_LOC scp -o StrictHostKeyChecking=no ubuntu@$NR_UE_VM_IP_ADDR:/home/ubuntu/tmp/cmake_targets/log/$CURRENT_NR_UE_LOG_FILE $ARCHIVES_LOC
try_cnt=$[$try_cnt+1] try_cnt=$((try_cnt+1))
continue continue
fi fi
@@ -2363,9 +2364,9 @@ function run_test_on_vm {
if [ $IPERF_STATUS -ne 0 ] if [ $IPERF_STATUS -ne 0 ]
then then
echo "UL test not OK" echo "UL test not OK"
try_cnt=$[$try_cnt+1] try_cnt=$((try_cnt+1))
else else
try_cnt=$[$try_cnt+10] try_cnt=$((try_cnt+10))
fi fi
done done
######### end of loop ######### end of loop