Skip to content
Snippets Groups Projects
Commit ea0dff50 authored by Luhan Cheng's avatar Luhan Cheng
Browse files

record failed module

parent 2a711a98
No related branches found
No related tags found
2 merge requests!464Fix listdeps,!442Smoke test
...@@ -31,6 +31,7 @@ fi ...@@ -31,6 +31,7 @@ fi
declare -a modules declare -a modules
failed_modules=()
IFS_orig=$IFS IFS_orig=$IFS
IFS=$'\n' IFS=$'\n'
...@@ -50,9 +51,10 @@ for i in $(head -n $NUM_MODULE $USAGE_REPORT); do ...@@ -50,9 +51,10 @@ for i in $(head -n $NUM_MODULE $USAGE_REPORT); do
echo '' > $OUTPUT_DIR/$name/$ver echo '' > $OUTPUT_DIR/$name/$ver
if [ ! -d $TESTCASE_DIR/$name ]; then if [ ! -d $TESTCASE_DIR/$name ]; then
echo "No testcase for $m found" | tee -a $REPORT echo "No testcase for $m found" | tee -a $REPORT
num_notest+=1 num_notest+=1
else else
ALL_EXEC=$(find $TESTCASE_DIR/$name -maxdepth 1 -executable -type f) ALL_EXEC=$(find $TESTCASE_DIR/$name -maxdepth 1 -executable -type f)
module_failed=1
for t_case in ${ALL_EXEC}; do for t_case in ${ALL_EXEC}; do
if [ $i == 'bintest' ] && ! $BINTEST;then break;fi if [ $i == 'bintest' ] && ! $BINTEST;then break;fi
orig_dir=$PWD orig_dir=$PWD
...@@ -67,17 +69,21 @@ for i in $(head -n $NUM_MODULE $USAGE_REPORT); do ...@@ -67,17 +69,21 @@ for i in $(head -n $NUM_MODULE $USAGE_REPORT); do
minor_error+=1 minor_error+=1
else else
num_failed+=1 num_failed+=1
module_failed=0
fi fi
echo "$m return non-zero exitcode $exitcode for testcase $t_case" 2>&1 | tee -a $REPORT echo "$m return non-zero exitcode $exitcode for testcase $t_case" 2>&1 | tee -a $REPORT
fi fi
done done
if [ module_failed ]; then
echo "$name/$ver" >> $OUTPUT_DIR/failed_modules.txt
fi
fi fi
module purge module purge
printf "Done" printf "Done"
done done
IFS=$IFS_orig IFS=$IFS_orig
echo "Summary" 2>&1 | tee -a $REPORT echo "Testcase summary" 2>&1 | tee -a $REPORT
echo "Failed: $num_failed" 2>&1 | tee -a $REPORT echo "Failed: $num_failed" 2>&1 | tee -a $REPORT
echo "Success: $num_success" 2>&1 | tee -a $REPORT echo "Success: $num_success" 2>&1 | tee -a $REPORT
echo "minor error: $minor_error, this is often due to executable not having --version option" 2>&1 | tee -a $REPORT echo "minor error: $minor_error, this is often due to executable not having --version option" 2>&1 | tee -a $REPORT
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment