[PATCH v2 2/8] metadata: test.sh: Print the test name and result

Petr Vorel <[email protected]>
Newsgroups gmane.linux.ltp
Message-ID <[email protected]>
Always print the test name with the result. This helps a readability
in the CI.

    * multiline_macro.c [OK]
    * regression.c [FAIL]
    regression.c output differs!
    --- tmp.json	2026-07-09 14:27:15.590074023 +0200
    +++ regression.c.json	2026-07-09 14:27:06.083967188 +0200
    @@ -6,7 +6,7 @@
	 ]
	],
	"doc": [
    -    "Test for regression group derived from the linux-git tag."
    +    "Test for regression group derived from the foo tag."
	],
	"groups": [
	 "regression"
    * tags.c [OK]

Signed-off-by: Petr Vorel <[email protected]>
---
* The same as in v1

 metadata/tests/test.sh | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/metadata/tests/test.sh b/metadata/tests/test.sh
index 475d721df0..a9ebc768f9 100755
--- a/metadata/tests/test.sh
+++ b/metadata/tests/test.sh
@@ -3,13 +3,15 @@
 fail=0
 
 for i in *.c; do
+	printf "* $i "
 	../metaparse $i > tmp.json
 	if ! diff tmp.json $i.json >/dev/null 2>&1; then
-		echo "***"
+		echo '[FAIL]'
 		echo "$i output differs!"
 		diff -u tmp.json $i.json
-		echo "***"
 		fail=1
+	else
+		echo '[OK]'
 	fi
 done
 
-- 
2.54.0


-- 
Mailing list info: https://lists.linux.it/listinfo/ltp
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.