From 89344c5dabd9b7f1a2609e3f6e1015f04cb6385a Mon Sep 17 00:00:00 2001 From: Raphael Defosseux Date: Thu, 21 Jun 2018 15:18:41 +0200 Subject: [PATCH] CI: improvements -- missing phy simulator logs in artifacts -- enhancement on HTML report Signed-off-by: Raphael Defosseux --- ci-scripts/Jenkinsfile-gitlab | 2 +- ci-scripts/reportBuildLocally.sh | 43 +++++++++++++++++++++----------- 2 files changed, 30 insertions(+), 15 deletions(-) diff --git a/ci-scripts/Jenkinsfile-gitlab b/ci-scripts/Jenkinsfile-gitlab index 7e82261ab8..ad97588d9b 100644 --- a/ci-scripts/Jenkinsfile-gitlab +++ b/ci-scripts/Jenkinsfile-gitlab @@ -82,7 +82,7 @@ pipeline { always { script { dir ('archives') { - sh "zip -r vm_build_logs.zip basic_sim enb_usrp cppcheck" + sh "zip -r vm_build_logs.zip basic_sim enb_usrp phy_sim cppcheck" } if(fileExists('archives/vm_build_logs.zip')) { archiveArtifacts artifacts: 'archives/vm_build_logs.zip' diff --git a/ci-scripts/reportBuildLocally.sh b/ci-scripts/reportBuildLocally.sh index 5194b81d4f..b4f2f324e7 100755 --- a/ci-scripts/reportBuildLocally.sh +++ b/ci-scripts/reportBuildLocally.sh @@ -71,8 +71,8 @@ function trigger_usage { function details_table { echo "

$1

" >> $3 - echo " " >> $3 - echo " " >> $3 + echo "
" >> $3 + echo " " >> $3 echo " " >> $3 echo " " >> $3 echo " " >> $3 @@ -119,8 +119,8 @@ function details_table { function summary_table_header { echo "

$1

" >> ./build_results.html - echo "
FileLine NumberStatus
" >> ./build_results.html - echo " " >> ./build_results.html + echo "
" >> ./build_results.html + echo " " >> ./build_results.html echo " " >> ./build_results.html echo " " >> ./build_results.html echo " " >> ./build_results.html @@ -177,9 +177,9 @@ function summary_table_footer { function sca_summary_table_header { echo "

$1

" >> ./build_results.html - echo "
ElementStatusNb Errors
" >> ./build_results.html - echo " " >> ./build_results.html - echo " " >> ./build_results.html + echo "
Error Type
" >> ./build_results.html + echo " " >> ./build_results.html + echo " " >> ./build_results.html echo " " >> ./build_results.html echo " " >> ./build_results.html echo " " >> ./build_results.html @@ -188,7 +188,7 @@ function sca_summary_table_header { function sca_summary_table_row { echo " " >> ./build_results.html - echo " " >> ./build_results.html + echo " " >> ./build_results.html if [ -f $1 ] then NB_ERRORS=`egrep "severity=\"error\"" $1 | egrep -c "id=\"$3\""` @@ -208,26 +208,27 @@ function sca_summary_table_row { } function sca_summary_table_footer { - echo " " >> ./build_results.html if [ -f $1 ] then NB_ERRORS=`egrep -c "severity=\"error\"" $1` + NB_WARNINGS=`egrep -c "severity=\"warning\"" $1` if [ -f ccp_error_cnt.txt ] then - echo " " >> ./build_results.html + echo " " >> ./build_results.html + echo " " >> ./build_results.html TOTAL_ERRORS=`cat ccp_error_cnt.txt` TOTAL_ERRORS=$((NB_ERRORS - TOTAL_ERRORS)) echo " " >> ./build_results.html - echo " " >> ./build_results.html + echo " " >> ./build_results.html echo " " >> ./build_results.html - echo " " >> ./build_results.html rm -f ccp_error_cnt.txt fi + echo " " >> ./build_results.html echo " " >> ./build_results.html echo " " >> ./build_results.html - NB_WARNINGS=`egrep -c "severity=\"warning\"" $1` echo " " >> ./build_results.html else + echo " " >> ./build_results.html echo " " >> ./build_results.html echo " " >> ./build_results.html echo " " >> ./build_results.html @@ -394,9 +395,23 @@ echo "" > ./build_results.html echo "" >> ./build_results.html echo "" >> ./build_results.html echo " Build Results for $JOB_NAME job build #$BUILD_ID" >> ./build_results.html +echo " " >> ./build_results.html echo "" >> ./build_results.html echo "" >> ./build_results.html -echo "

Job Summary -- Job: $JOB_NAME -- Build-ID: $BUILD_ID

" >> ./build_results.html +echo "
Error / Warning TypeNb ErrorsNb Warnings
$2$2
Others
Others$TOTAL_ERRORSN/A$NB_WARNINGS
Total$NB_ERRORS$NB_WARNINGS
TotalUnknownUnknown
" >> ./build_results.html +echo " " >> ./build_results.html +echo " " >> ./build_results.html +echo " " >> ./build_results.html +echo " " >> ./build_results.html +echo "
" >> ./build_results.html +echo " " >> ./build_results.html +echo " \"\"" >> ./build_results.html +echo " " >> ./build_results.html +echo " " >> ./build_results.html +echo " " >> ./build_results.html +echo " Job Summary -- Job: eNb-CI -- Build-ID: 23" >> ./build_results.html +echo "
" >> ./build_results.html +echo "
" >> ./build_results.html echo " " >> ./build_results.html echo " " >> ./build_results.html echo " " >> ./build_results.html
GIT Repository