Cirrus-CI: Check for final "Uptime" message

The last thing printed by the kernel after shutdown is Uptime: <time>.
In the CI boot test script add a check for this, to ensure that shutdown
is successful.  A test branch of mine panicked during shutdown, but
still reported success in Cirrus-CI.

Reviewed by:	kevans
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D48823
This commit is contained in:
Ed Maste
2025-02-03 13:09:23 -05:00
parent e917958c36
commit 6180d0382d
+2 -2
View File
@@ -125,8 +125,8 @@ timeout 300 \
-snapshot -hda $hda 2>&1 | tee ${BOOTLOG}
# Check whether we succesfully booted...
if grep -q 'Hello world.' ${BOOTLOG}; then
echo "OK"
if grep -q 'Hello world.' ${BOOTLOG} && egrep -q '^Uptime: ' ${BOOTLOG}; then
echo "Boot successful"
else
die "Did not boot successfully, see ${BOOTLOG}"
fi