aboutsummaryrefslogtreecommitdiff
path: root/t/t3902-quoted.sh
diff options
context:
space:
mode:
authorRamsay Jones <ramsay@ramsay1.demon.co.uk>2008-08-26 18:52:57 +0100
committerJunio C Hamano <gitster@pobox.com>2008-08-26 16:25:30 -0700
commit2b8437321901cf1559527090f5a475f4924031e5 (patch)
tree539a94cfd77d589de79d2f276cd2b349093dfe9f /t/t3902-quoted.sh
parentd47fb8b099d38cde7d3b27b44cc86cd720284d39 (diff)
downloadgit-2b8437321901cf1559527090f5a475f4924031e5.tar.gz
git-2b8437321901cf1559527090f5a475f4924031e5.tar.xz
Suppress some bash redirection error messages
In particular, when testing if the filesystem allows tabs in filenames, bash issues an error something like: ./t4016-diff-quote.sh: pathname with HT: No such file or directory which is caused by the failure of the (stdout) redirection, since the file cannot be created. In order to suppress the error message, you must redirect stderr to /dev/null, *before* the stdout redirection on the command-line. Also, remove a redundant filesystem check from the begining of the t3902-quoted.sh test and standardise the "test skipped" message to 'say' on exit. Signed-off-by: Ramsay Jones <ramsay@ramsay1.demon.co.uk> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t3902-quoted.sh')
-rwxr-xr-xt/t3902-quoted.sh8
1 files changed, 1 insertions, 7 deletions
diff --git a/t/t3902-quoted.sh b/t/t3902-quoted.sh
index fe4fb5116..586805242 100755
--- a/t/t3902-quoted.sh
+++ b/t/t3902-quoted.sh
@@ -7,12 +7,6 @@ test_description='quoted output'
. ./test-lib.sh
-P1='pathname with HT'
-: >"$P1" 2>&1 && test -f "$P1" && rm -f "$P1" || {
- echo >&2 'Filesystem does not support HT in names'
- test_done
-}
-
FN='濱野'
GN='純'
HT=' '
@@ -20,7 +14,7 @@ LF='
'
DQ='"'
-echo foo > "Name and an${HT}HT"
+echo foo 2>/dev/null > "Name and an${HT}HT"
test -f "Name and an${HT}HT" || {
# since FAT/NTFS does not allow tabs in filenames, skip this test
say 'Your filesystem does not allow tabs in filenames, test skipped.'