From 8b5c712c9669aa5943c7605eaf70c729213e0b33 Mon Sep 17 00:00:00 2001 From: Pierre Pronchery Date: Wed, 5 Jun 2024 19:35:32 +0200 Subject: [PATCH] tests: improve the output on macOS --- tests/tests.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tests/tests.sh b/tests/tests.sh index f05cbb0..6aeee2c 100755 --- a/tests/tests.sh +++ b/tests/tests.sh @@ -29,8 +29,11 @@ #variables [ -n "$OBJDIR" ] || OBJDIR="./" PROGNAME="tests.sh" +SYSTEM="$(uname -s)" #executables DATE="date" +ECHO="echo" +[ "$SYSTEM" = "Darwin" ] && ECHO="/bin/echo" #functions @@ -47,7 +50,7 @@ _run() test="$1" shift - echo -n "$test:" 1>&2 + $ECHO -n "$test:" 1>&2 (echo echo "Testing: $test" "$@" testexe="./$test"