From 07ea2b672b9061a07923b3ecd5c2206a6c8e2a18 Mon Sep 17 00:00:00 2001 From: AnotherTest Date: Wed, 29 Jul 2020 04:15:33 +0430 Subject: [PATCH] Shell: Tweak tests to use 'echo -n' when newlines are significant --- Shell/Tests/valid.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Shell/Tests/valid.sh b/Shell/Tests/valid.sh index 27f02bc128..6453d5f21b 100644 --- a/Shell/Tests/valid.sh +++ b/Shell/Tests/valid.sh @@ -85,7 +85,7 @@ rm -fr sh-test # Setopt setopt --inline_exec_keep_empty_segments -test "$(echo "a\n\nb")" = "a b" || fail inline_exec_keep_empty_segments has no effect +test "$(echo -n "a\n\nb")" = "a b" || fail inline_exec_keep_empty_segments has no effect setopt --no_inline_exec_keep_empty_segments -test "$(echo "a\n\nb")" = "a b" || fail cannot unset inline_exec_keep_empty_segments +test "$(echo -n "a\n\nb")" = "a b" || fail cannot unset inline_exec_keep_empty_segments