aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGuilhem Moulin <guilhem@fripost.org>2021-02-21 12:22:06 +0100
committerGuilhem Moulin <guilhem@fripost.org>2021-02-21 12:22:06 +0100
commit7545130ac74c5a6f3dfa62087ac0287686248eec (patch)
treec704f0b80edb3349d1a15ce2b468fdf709d03815
parent543578b20187836a83d84c7cd669cb2448e3a3d7 (diff)
test suite: Don't try to show stderr if it's empty.
-rwxr-xr-xtest8
1 files changed, 5 insertions, 3 deletions
diff --git a/test b/test
index c9aaef8..4fdfdbc 100755
--- a/test
+++ b/test
@@ -197,9 +197,11 @@ run() {
set +x
local rv=\$? i
if [ \$rv -eq 0 ]; then rv=1; fi
- echo "vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv"
- cat <"\$STDERR" >&2
- echo "^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^"
+ if [ -s "\$STDERR" ]; then
+ echo "vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv"
+ cat <"\$STDERR" >&2
+ echo "^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^"
+ fi
[ \$# -eq 0 ] || echo "Error: \$*" >&2
exit \$rv
}