mirror of
https://github.com/systemd/systemd.git
synced 2025-01-11 09:18:07 +03:00
test: do not lose logs of late failures in TEST-02-UNITTESTS
Due to set -e, if the wait() fails (eg: because of an assert in the waited task), report_result() never runs and logs are lost
This commit is contained in:
parent
35cde9e935
commit
7d3f9bf493
@ -78,10 +78,12 @@ done
|
||||
|
||||
# Wait for remaining running tasks
|
||||
for key in "${!running[@]}"; do
|
||||
wait ${running[$key]}
|
||||
ec=$?
|
||||
wait ${running[$key]} && ec=0 || ec=$?
|
||||
report_result "$key" $ec
|
||||
unset running["$key"]
|
||||
done
|
||||
|
||||
# Test logs are sometimes lost, as the system shuts down immediately after
|
||||
journalctl --sync
|
||||
|
||||
exit 0
|
||||
|
Loading…
Reference in New Issue
Block a user