diff options
Diffstat (limited to 'meta/recipes-support/libusb/libusb1/run-ptest')
-rwxr-xr-x | meta/recipes-support/libusb/libusb1/run-ptest | 32 |
1 files changed, 23 insertions, 9 deletions
diff --git a/meta/recipes-support/libusb/libusb1/run-ptest b/meta/recipes-support/libusb/libusb1/run-ptest index 646a966ef9..eaa47a2bc4 100755 --- a/meta/recipes-support/libusb/libusb1/run-ptest +++ b/meta/recipes-support/libusb/libusb1/run-ptest @@ -4,12 +4,26 @@ echo echo "---------------------------- libusb1 tests ---------------------------" echo -./stress | tr '\n' ' ' | \ -sed 's/Starting test run: \([a-zA-Z_]*\)\.\.\. \([a-zA-Z_]*\) (.) /\2 \1\n/g' | \ -sed '$d' | \ -sed '{ - s/^Success/PASS:/g - s/^Failure/FAIL:/g - s/^Error/FAIL:/g - s/^Skip/SKIP:/g -}' +./stress | { \ +while read -r str +do + echo "$str" + if [ "${str#*Starting test run:}" != "$str" ] + then + name="${str#Starting test run: }" + name="${name%...}" + else + case "$str" in + "Success (0)") + echo "PASS: $name" + ;; + "Failure (1)" | "Error (2)") + echo "FAIL: $name" + ;; + "Skip (3)") + echo "SKIP: $name" + ;; + esac + fi +done +} |