Files
meta-openembedded/meta-python/recipes-devtools/python/python3-pydbus/run-ptest
T
Khem Raj cfe0f858c2 python3-pydbus: skip ptest cases gracefully when dbus-launch is missing
Guard each shell test case with a dbus-launch availability check and
emit SKIP instead of hard-failing when it isn't installed.

AI-Generated: Uses Claude Code
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2026-08-29 21:43:04 -07:00

19 lines
475 B
Bash

#!/bin/sh
for case in `find tests -type f -name '*.sh'`; do
if ! command -v dbus-launch >/dev/null 2>&1; then
echo "SKIP: ${case} (dbus-launch not installed)"
continue
fi
bash $case python3 >$case.output 2>&1
ret=$?
if [ $ret -ne 0 ]; then
cat $case.output
echo "FAIL: ${case}"
elif grep -i 'SKIP' $case.output; then
echo "SKIP: ${case}"
else
echo "PASS: ${case}"
fi
rm -f $case.output
done