diff --git a/scenarios/check.sh b/scenarios/check.sh index e038f2ae..26f3da35 100755 --- a/scenarios/check.sh +++ b/scenarios/check.sh @@ -82,12 +82,19 @@ function run_sipp if [ -f ${SCEN_CHECK_DIR}/sipp_scenario_responder.xml ]; then ${BASE_DIR}/sipp.sh -d ${DOMAIN} -r ${SCEN_CHECK_DIR}/sipp_scenario_responder_reg.xml &> /dev/null ${BASE_DIR}/sipp.sh -d ${DOMAIN} -r ${SCEN_CHECK_DIR}/sipp_scenario_responder.xml &> /dev/null & + responder_pid=$! fi # let's fire sipp scenario ${BASE_DIR}/sipp.sh -d ${DOMAIN} $1 status=$? if [ -f ${SCEN_CHECK_DIR}/sipp_scenario_responder.xml ]; then + ps -p${responder_pid} &> /dev/null + ps_status=$? + if [ ${ps_status} -eq 0 ]; then + echo "sipp responder not finished yet. Waiting 5 secs" + sleep 5 + fi ${BASE_DIR}/sipp.sh -d ${DOMAIN} -r ${SCEN_CHECK_DIR}/sipp_scenario_responder_unreg.xml &> /dev/null fi