rsyslog/tests/rscript_backticks_empty_envvar-vg.sh
Rainer Gerhards 4b01dca190
testbench: add test for backticks parameters
checking that echo on non-exist env var does not abort rsyslog

see also https://github.com/rsyslog/rsyslog/issues/3006
2018-11-03 17:57:20 +01:00

17 lines
385 B
Bash
Executable File

#!/bin/bash
# added 2018-11-02 by rgerhards
# see also https://github.com/rsyslog/rsyslog/issues/3006
# released under ASL 2.0
. ${srcdir:=.}/diag.sh init
generate_conf
add_conf '
if `echo $DOES_NOT_EXIST` == "" then
action(type="omfile" file=`echo $RSYSLOG_OUT_LOG`)
'
startup_vg
shutdown_when_empty
wait_shutdown_vg
check_exit_vg
content_check --regex "rsyslogd: .*start"
exit_test