fix(functional): handle optional skip reporting

This commit is contained in:
chainsx
2026-08-16 15:33:19 +08:00
parent 10b19c7da5
commit cd6e67dfd1
3 changed files with 7 additions and 3 deletions
+3 -1
View File
@@ -69,7 +69,9 @@ _realtimeRunCase() {
if ! printf '%s\n' "${TEST_SERVER_1_PASSWORD:-openruyi}" |
sudo -S chrt -r 1 true >/dev/null 2>&1; then
rlLogWarning "SKIP: SCHED_RR is not available"
rlTestSkip "LTP Realtime requires SCHED_RR support"
if type -t rlTestSkip >/dev/null 2>&1; then
rlTestSkip "LTP Realtime requires SCHED_RR support"
fi
return 0
fi
@@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/bash
# Functional test: kernel - realtime - sched_latency
# LTP Realtime: run.sh -t func/sched_latency
# Beakerlib-based test with lifecycle management
@@ -24,7 +24,9 @@ rlJournalStart
rlPass "Update PCI ID database"
elif grep -qiE 'certificate|download failed|resolve|timed out|network' "$UpdateLog"; then
rlLogWarning "SKIP: PCI ID download is unavailable"
rlTestSkip "PCI ID download requires external network access"
if type -t rlTestSkip >/dev/null 2>&1; then
rlTestSkip "PCI ID download requires external network access"
fi
else
rlFail "update-pciids failed (exit=$UpdateRc)"
fi