From 3b92cfb5c4cace00a3d55053f31fcb0d703ac02a Mon Sep 17 00:00:00 2001 From: GONG Jie Date: Mon, 18 Jul 2016 20:49:05 +0800 Subject: [PATCH] [xCAT Jenkins Email Report] Remove comment from test bundle file, and do chomp()ing --- .../share/xcat/tools/jenkins/testreport/xcatjk-log2sql.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/xCAT-server/share/xcat/tools/jenkins/testreport/xcatjk-log2sql.sh b/xCAT-server/share/xcat/tools/jenkins/testreport/xcatjk-log2sql.sh index d3cff55e3..bc83667e1 100755 --- a/xCAT-server/share/xcat/tools/jenkins/testreport/xcatjk-log2sql.sh +++ b/xCAT-server/share/xcat/tools/jenkins/testreport/xcatjk-log2sql.sh @@ -284,8 +284,11 @@ function xcattestbundle2sql() while read -r test_case_name do - # Need chomp ${test_case_name} + # Remove any comment + test_case_name="${test_case_name%%#*}" + # Chomp test_case_name=$(echo ${test_case_name}) + [ -z "${test_case_name}" ] && continue while read -r ; do echo "${REPLY}" ; done <<-EOF INSERT INTO TestCase (TestCaseId, TestCaseName)