File tree 1 file changed +23
-1
lines changed
1 file changed +23
-1
lines changed Original file line number Diff line number Diff line change @@ -188,11 +188,33 @@ echo
188
188
echo " ======================================================================"
189
189
echo
190
190
191
- for log in $( ls -1 ${PATH_TESTS} .log ${PATH_EXAMPLES} .log) ; do
191
+ LOG_FILES=" "
192
+ NT=$( ls -1 ${PATH_TESTS} .log 2> /dev/null | wc -l)
193
+ if [ $NT -gt 0 ]; then
194
+ LOG_FILES=" $LOG_FILES $( ls -1 ${PATH_TESTS} .log | xargs) "
195
+ fi
196
+ NE=$( ls -1 ${PATH_EXAMPLES} .log 2> /dev/null | wc -l)
197
+ if [ $NE -gt 0 ]; then
198
+ LOG_FILES=" $LOG_FILES $( ls -1 ${PATH_EXAMPLES} .log | xargs) "
199
+ fi
200
+ if [ $(( $NT + $NE )) -eq 0 ]; then
201
+ echo
202
+ echo " FATAL ERROR: no log files found, but number of failed tests equals $ANY_TEST_FAILED !"
203
+ echo
204
+ exit 1
205
+ fi
206
+
207
+ for log in $LOG_FILES ; do
192
208
echo " >>>>>>> LOG $log "
193
209
cat $log
194
210
echo
195
211
echo
196
212
done
197
213
214
+ if [ $(( $NT + $NE )) -ne $ANY_TEST_FAILED ]; then
215
+ echo
216
+ echo " ERROR: incorrect number of log files: ANY_TEST_FAILED=$ANY_TEST_FAILED != ($NT + $NE )"
217
+ echo
218
+ fi
219
+
198
220
exit 1
You can’t perform that action at this time.
0 commit comments