From: Miroslav Lichvar Date: Thu, 25 Apr 2019 15:25:19 +0000 (+0200) Subject: test: redirect error messages in system tests X-Git-Tag: 3.5-pre1~12 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=bbe1e69dccbeac4221ebea4e40444058f09d3bc6;p=thirdparty%2Fchrony.git test: redirect error messages in system tests --- diff --git a/test/system/test.common b/test/system/test.common index d83d9b64..9151e100 100644 --- a/test/system/test.common +++ b/test/system/test.common @@ -227,7 +227,7 @@ start_chronyd() { trap stop_chronyd EXIT - $CHRONYD_WRAPPER "$chronyd" $(get_chronyd_options) + $CHRONYD_WRAPPER "$chronyd" $(get_chronyd_options) > "$TEST_DIR/chronyd.out" 2>&1 [ $? -eq 0 ] && [ -f "$pidfile" ] && ps -p "$(cat "$pidfile")" > /dev/null && test_ok || test_error } @@ -248,7 +248,7 @@ stop_chronyd() { test_message 1 0 "stopping chronyd" - if ! kill "$pid"; then + if ! kill "$pid" 2> /dev/null; then test_error return fi