aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLoys Ollivier <lollivier@baylibre.com>2017-11-09 11:10:00 +0100
committerLoys Ollivier <lollivier@baylibre.com>2017-11-09 11:16:58 +0100
commit9aae8071429333a24277a9b5685cf06e4f593892 (patch)
treeef9501d0fcc3afc612b7cebe8a63a9fccfced54a
parent14f4baf26da1c9db08cdced214ee7711136a707b (diff)
Yocto ptest wrapper extend ptest seteel_4.99.3eel/4.99.34.99.3
Extend the set of ptests to run to: acl attr bluez5 busybox dbus-test. Reduce the LAVA output to summarize the results of ptests. Change-Id: I088789dbc148f4007c8b9971adeadce689cbb6b0 Signed-off-by: Loys Ollivier <lollivier@baylibre.com>
-rwxr-xr-xcommon/scripts/ptest-lava-wrapper.sh11
1 files changed, 7 insertions, 4 deletions
diff --git a/common/scripts/ptest-lava-wrapper.sh b/common/scripts/ptest-lava-wrapper.sh
index e49db5d..56a1049 100755
--- a/common/scripts/ptest-lava-wrapper.sh
+++ b/common/scripts/ptest-lava-wrapper.sh
@@ -1,11 +1,11 @@
#!/bin/bash
-REQUIREDPTESTS="busybox"
+REQUIREDPTESTS="acl attr bluez5 busybox dbus-test"
# Check if ptest packages are installed
command -v ptest-runner >/dev/null 2>&1
if [ $? -ne 0 ] ; then
- lava-test-case ptest-installed --result FAIL
+ lava-test-case ptest-installed --result SKIP
else
# Run ptests for specified packages
for unit in ${REQUIREDPTESTS}; do
@@ -17,7 +17,10 @@ else
# sed 2: remove any special character
# sed 3: find status and test name, wrap it in a lava-test-case call
# sh: execute the lava-test-case commands
- echo "$UNIT_LOG" | grep -e 'PASS' -e 'FAIL' | sed 's/ /-/g' | sed 's/[^a-z|A-Z|0-9|-]//g' | sed 's/\([^-]*\)-\(.*\)/lava-test-case \2 --result \1/' | sh
+ test_pass=$(echo "$UNIT_LOG" | grep -e 'PASS' | wc -l)
+ test_fail=$(echo "$UNIT_LOG" | grep -e 'FAIL' | wc -l)
+ lava-test-case passed-commands --result PASS --measurement $test_pass --units pass
+ lava-test-case failed-commands --result FAIL --measurement $test_fail --units fail
lava-test-set stop ptest-$unit
else
lava-test-case ptest-runner ${unit} --result fail
@@ -27,4 +30,4 @@ else
fi
# Wait for LAVA to parse all the tests from stdout
-sleep 60 \ No newline at end of file
+sleep 15