Files
sdcv/tests/t_interactive
2013-07-06 18:36:42 +00:00

21 lines
345 B
Bash
Executable File

#!/bin/sh
# check that in not-interactive mode sdcv not wait any input
PATH_TO_SDCV="$1"
if test ! -x "$PATH_TO_SDCV"; then
echo "Can not find sdcv binary $1" >&2
exit 1
fi
"$PATH_TO_SDCV" -n >/dev/null 2>&1 &
PID=$!
sleep 1
if kill -0 $PID >/dev/null 2>&1 ; then
echo "process wait input: $PID, test failed" >&2
exit 1
fi
exit 0