From: Zhang Peng <peng.zhang1...@windriver.com>

This change consolidates the output format of the ptest command
into a single common format.
The format selected is the automake "simple test" format:
    "result: testname"

Signed-off-by: Zhang Peng <peng.zhang1...@windriver.com>
---
 .../recipes-extended/hiredis/hiredis/run-ptest  | 17 ++++++++++++++++-
 1 file changed, 16 insertions(+), 1 deletion(-)

diff --git a/meta-oe/recipes-extended/hiredis/hiredis/run-ptest 
b/meta-oe/recipes-extended/hiredis/hiredis/run-ptest
index 59b747dbd8..8d450b881f 100644
--- a/meta-oe/recipes-extended/hiredis/hiredis/run-ptest
+++ b/meta-oe/recipes-extended/hiredis/hiredis/run-ptest
@@ -1,3 +1,18 @@
 #!/bin/sh
 
-TEST_SSL=0 TEST_ASYNC=0 ./test.sh
+TEST_SSL=0 TEST_ASYNC=0 ./test.sh | sed -e 's/PASSED/PASS/g' -e 
's/FAILED/FAIL/g' -e 's/SKIPPED/SKIP/g' | awk '
+{
+    if ($NF == "\033[0;32mPASS\033[0;0m" || $NF == "\033[0;31mFAIL\033[0;0m" 
|| $NF == "\033[01;33mSKIP\033[0;0m") {
+        printf "%s: %s\n", $NF, $0
+    } else {
+        print
+    }
+}'| awk '{
+    if ($NF == "\033[0;32mPASS\033[0;0m" || $NF == "\033[0;31mFAIL\033[0;0m" 
|| $NF == "\033[01;33mSKIP\033[0;0m") {
+        $NF = ""
+        print $0
+    } else {
+    print
+    }       
+}' | awk '{gsub(/:/,"",$NF)}1'
+
-- 
2.44.0

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#110939): 
https://lists.openembedded.org/g/openembedded-devel/message/110939
Mute This Topic: https://lists.openembedded.org/mt/106715624/21656
Group Owner: openembedded-devel+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-devel/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to