diff --git a/test.sh b/test.sh index 280d9e7..70bf468 100755 --- a/test.sh +++ b/test.sh @@ -1458,4 +1458,19 @@ minishell: printff: command not found bonjour EOF +when_run <<"EOF" "redirection expansion when no commands are included" +export VAR="bonjour hello" +>$VAR>hey +ls +>hey>$VAR +ls +>hey>$VAR>hey>hey +ls +EOF +expecting <<"EOF" +minishell: $VAR: ambiguous redirect +minishell: $VAR: ambiguous redirect +minishell: $VAR: ambiguous redirect +EOF + finalize