summaryrefslogtreecommitdiff
path: root/t/t0025-crlf-auto.sh
diff options
context:
space:
mode:
authorElia Pinto <gitter.spiros@gmail.com>2014-06-06 14:55:55 (GMT)
committerJunio C Hamano <gitster@pobox.com>2014-06-09 22:53:41 (GMT)
commitfbaff7a26225e4e3b9088aae83c9febcd8bb6825 (patch)
tree54c24594b5fe3c16cc2c980760e191ace46ddd1f /t/t0025-crlf-auto.sh
parentce5dadb6165c58f6a3a121a9373e6d3ae23b35b4 (diff)
downloadgit-fbaff7a26225e4e3b9088aae83c9febcd8bb6825.zip
git-fbaff7a26225e4e3b9088aae83c9febcd8bb6825.tar.gz
git-fbaff7a26225e4e3b9088aae83c9febcd8bb6825.tar.bz2
t/t0025-crlf-auto.sh: avoid "test <cond> -a/-o <cond>"
The construct is error-prone; "test" being built-in in most modern shells, the reason to avoid "test <cond> && test <cond>" spawning one extra process by using a single "test <cond> -a <cond>" no longer exists. Signed-off-by: Elia Pinto <gitter.spiros@gmail.com> Reviewed-by: Matthieu Moy <Matthieu.Moy@imag.fr> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t0025-crlf-auto.sh')
-rwxr-xr-xt/t0025-crlf-auto.sh6
1 files changed, 3 insertions, 3 deletions
diff --git a/t/t0025-crlf-auto.sh b/t/t0025-crlf-auto.sh
index b0e5694..28102de 100755
--- a/t/t0025-crlf-auto.sh
+++ b/t/t0025-crlf-auto.sh
@@ -36,7 +36,7 @@ test_expect_success 'default settings cause no changes' '
onediff=$(git diff one) &&
twodiff=$(git diff two) &&
threediff=$(git diff three) &&
- test -z "$onediff" -a -z "$twodiff" -a -z "$threediff"
+ test -z "$onediff" && test -z "$twodiff" && test -z "$threediff"
'
test_expect_success 'crlf=true causes a CRLF file to be normalized' '
@@ -111,7 +111,7 @@ test_expect_success 'autocrlf=true does not normalize CRLF files' '
onediff=$(git diff one) &&
twodiff=$(git diff two) &&
threediff=$(git diff three) &&
- test -z "$onediff" -a -z "$twodiff" -a -z "$threediff"
+ test -z "$onediff" && test -z "$twodiff" && test -z "$threediff"
'
test_expect_success 'text=auto, autocrlf=true _does_ normalize CRLF files' '
@@ -126,7 +126,7 @@ test_expect_success 'text=auto, autocrlf=true _does_ normalize CRLF files' '
onediff=$(git diff one) &&
twodiff=$(git diff two) &&
threediff=$(git diff three) &&
- test -z "$onediff" -a -n "$twodiff" -a -z "$threediff"
+ test -z "$onediff" && test -n "$twodiff" && test -z "$threediff"
'
test_expect_success 'text=auto, autocrlf=true does not normalize binary files' '