From fd3561bae0097fab3df79d30b2f171169d75258a Mon Sep 17 00:00:00 2001 From: =?utf8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= Date: Tue, 8 Oct 2019 11:11:49 +0200 Subject: [PATCH] test/TEST-31-DEVICE-ENUMERATION: do not use -x to avoid grep loop https://github.com/systemd/systemd/pull/13746#issuecomment-539410752: > [grep] now matches the grep command itself, as it's logged into journal as well, thanks to set -x. Also, use journalctl --grep and -t to make things a bit quicker. --- test/TEST-31-DEVICE-ENUMERATION/testsuite.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/TEST-31-DEVICE-ENUMERATION/testsuite.sh b/test/TEST-31-DEVICE-ENUMERATION/testsuite.sh index aa94d59..047c1be 100755 --- a/test/TEST-31-DEVICE-ENUMERATION/testsuite.sh +++ b/test/TEST-31-DEVICE-ENUMERATION/testsuite.sh @@ -1,8 +1,8 @@ #!/bin/bash -set -ex +set -e set -o pipefail -if journalctl -b | grep -e '\.device: Changed plugged -> dead'; then +if journalctl -b -t systemd --grep '\.device: Changed plugged -> dead'; then exit 1 fi -- 2.7.4