From 811cbbdb1d20f7ddd47ac5162c684afd48aef6a2 Mon Sep 17 00:00:00 2001 From: Marco Capetta Date: Fri, 24 May 2019 15:18:34 +0200 Subject: [PATCH] TT#56951 Stop scenario execution if coredump file are generated Only kamailio, sems and asterisk coredupms are checked Change-Id: I87f24dfc4ef6cfdf3f8f4a2147bed8efdaa4b045 --- run_tests.sh | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/run_tests.sh b/run_tests.sh index 95a1448b..318d62b3 100755 --- a/run_tests.sh +++ b/run_tests.sh @@ -8,6 +8,7 @@ GROUP="${GROUP:-scenarios}" LOG_DIR="${BASE_DIR}/log/${GROUP}" MLOG_DIR="${BASE_DIR}/mem" KAM_DIR="/tmp/cfgtest" +COREDUMP_DIR="/ngcp-data/coredumps" PROFILE="CE" OPTS=(-P -T) DOMAIN="spce.test" @@ -323,6 +324,18 @@ for t in ${SCENARIOS}; do fi echo "$(date) - =================================================================================" + + # Check if core files have been geneared during the test execution + coredumps=$(find "${COREDUMP_DIR}" -regex '.*kamailio.*\|.*sems.*\|.*asterisk.*' -print) + if [ -n "${coredumps}" ]; then + echo "$(date) - =================================================================================" + echo "$(date) - One or more coredump files have been generated during the test execution." + echo "$(date) - Check the following files under the folder '${COREDUMP_DIR}':" + echo "${coredumps}" + echo "$(date) - =================================================================================" + error_flag=1 + break + fi done # Hack to allow tcpdump to capture all the packages and kamailio to write all the json files