miaou-bash.test.bash
This commit is contained in:
@@ -91,13 +91,14 @@ function fail_stderr_grep {
|
||||
((test_count++))
|
||||
cmd="$MIAOU_BASH_DIR/test/stub/scenario.bash $1"
|
||||
stderr_line="$2"
|
||||
if ! $cmd 2>"$TMP_ERR" 3>/dev/null && grep -q "$stderr_line" "$TMP_ERR"; then
|
||||
|
||||
if ! $cmd 2>"$TMP_ERR" && grep -q "$stderr_line" "$TMP_ERR"; then
|
||||
echo -n .
|
||||
return
|
||||
fi
|
||||
|
||||
echo -n F
|
||||
failures+=("$cmd 2>&1 3>/dev/null | grep \"$stderr_line\"")
|
||||
failures+=("$cmd 2>&1 | grep -q \"$stderr_line\"")
|
||||
return 1
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user