From 571fdaafacb685da1e4201612c14f4cf6a761293 Mon Sep 17 00:00:00 2001 From: Thomas Haller Date: Fri, 19 Mar 2021 11:37:41 +0100 Subject: [PATCH] tests/client: rework error handling in "test-client.sh" script The script runs with "set -e", as such `cmd && r=ok` seems wrong. It worked apparently, but I don't understand why. Anyway, change it. Fixes: e64370341850 ('tests/client: run "test-client.py" also for meson') --- src/tests/client/test-client.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/tests/client/test-client.sh b/src/tests/client/test-client.sh index 52fbd5c94d..985d07c91a 100755 --- a/src/tests/client/test-client.sh +++ b/src/tests/client/test-client.sh @@ -56,8 +56,8 @@ export NM_TEST_CLIENT_BUILDDIR="$BUILDDIR" # afterwards. The only reason is that when you run with `make -j` that the # test output is grouped together. -r="" -"$PYTHON" "$SRCDIR/src/tests/client/test-client.py" -v &> "$BUILDDIR/src/tests/client/test-client.log" && r=ok +r="ok" +"$PYTHON" "$SRCDIR/src/tests/client/test-client.py" -v &> "$BUILDDIR/src/tests/client/test-client.log" || r=fail cat "$BUILDDIR/src/tests/client/test-client.log"