t4000-t4999: fix broken &&-chains
Signed-off-by: Eric Sunshine <sunshine@sunshineco.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
parent
b6c32f63f3
commit
f957f03b60
@ -180,7 +180,7 @@ test_expect_success 'setup for many rename source candidates' '
|
|||||||
git add "path??" &&
|
git add "path??" &&
|
||||||
test_tick &&
|
test_tick &&
|
||||||
git commit -m "hundred" &&
|
git commit -m "hundred" &&
|
||||||
(cat path1; echo new) >new-path &&
|
(cat path1 && echo new) >new-path &&
|
||||||
echo old >>path1 &&
|
echo old >>path1 &&
|
||||||
git add new-path path1 &&
|
git add new-path path1 &&
|
||||||
git diff -l 4 -C -C --cached --name-status >actual 2>actual.err &&
|
git diff -l 4 -C -C --cached --name-status >actual 2>actual.err &&
|
||||||
|
@ -127,17 +127,17 @@ test_expect_success setup '
|
|||||||
|
|
||||||
for n in $sample
|
for n in $sample
|
||||||
do
|
do
|
||||||
( zs $n ; echo a ) >file-a$n &&
|
( zs $n && echo a ) >file-a$n &&
|
||||||
( echo b; zs $n; echo ) >file-b$n &&
|
( echo b && zs $n && echo ) >file-b$n &&
|
||||||
( printf c; zs $n ) >file-c$n &&
|
( printf c && zs $n ) >file-c$n &&
|
||||||
( echo d; zs $n ) >file-d$n &&
|
( echo d && zs $n ) >file-d$n &&
|
||||||
|
|
||||||
git add file-a$n file-b$n file-c$n file-d$n &&
|
git add file-a$n file-b$n file-c$n file-d$n &&
|
||||||
|
|
||||||
( zs $n ; echo A ) >file-a$n &&
|
( zs $n && echo A ) >file-a$n &&
|
||||||
( echo B; zs $n; echo ) >file-b$n &&
|
( echo B && zs $n && echo ) >file-b$n &&
|
||||||
( printf C; zs $n ) >file-c$n &&
|
( printf C && zs $n ) >file-c$n &&
|
||||||
( echo D; zs $n ) >file-d$n &&
|
( echo D && zs $n ) >file-d$n &&
|
||||||
|
|
||||||
expect_pattern $n || return 1
|
expect_pattern $n || return 1
|
||||||
|
|
||||||
|
@ -12,12 +12,12 @@ NS="$N$N$N$N$N$N$N$N$N$N$N$N$N"
|
|||||||
test_expect_success setup '
|
test_expect_success setup '
|
||||||
|
|
||||||
(
|
(
|
||||||
echo "A $NS"
|
echo "A $NS" &&
|
||||||
for c in B C D E F G H I J K
|
for c in B C D E F G H I J K
|
||||||
do
|
do
|
||||||
echo " $c"
|
echo " $c"
|
||||||
done
|
done &&
|
||||||
echo "L $NS"
|
echo "L $NS" &&
|
||||||
for c in M N O P Q R S T U V
|
for c in M N O P Q R S T U V
|
||||||
do
|
do
|
||||||
echo " $c"
|
echo " $c"
|
||||||
@ -34,7 +34,7 @@ test_expect_success 'hunk header truncation with an overly long line' '
|
|||||||
|
|
||||||
git diff | sed -n -e "s/^.*@@//p" >actual &&
|
git diff | sed -n -e "s/^.*@@//p" >actual &&
|
||||||
(
|
(
|
||||||
echo " A $N$N$N$N$N$N$N$N$N2"
|
echo " A $N$N$N$N$N$N$N$N$N2" &&
|
||||||
echo " L $N$N$N$N$N$N$N$N$N1"
|
echo " L $N$N$N$N$N$N$N$N$N1"
|
||||||
) >expected &&
|
) >expected &&
|
||||||
test_cmp actual expected
|
test_cmp actual expected
|
||||||
|
@ -498,7 +498,7 @@ test_expect_success 'given commit --submodule=short' '
|
|||||||
test_expect_success 'setup .git file for sm2' '
|
test_expect_success 'setup .git file for sm2' '
|
||||||
(cd sm2 &&
|
(cd sm2 &&
|
||||||
REAL="$(pwd)/../.real" &&
|
REAL="$(pwd)/../.real" &&
|
||||||
mv .git "$REAL"
|
mv .git "$REAL" &&
|
||||||
echo "gitdir: $REAL" >.git)
|
echo "gitdir: $REAL" >.git)
|
||||||
'
|
'
|
||||||
|
|
||||||
@ -527,7 +527,7 @@ test_expect_success 'diff --submodule with objects referenced by alternates' '
|
|||||||
git commit -m "sub a"
|
git commit -m "sub a"
|
||||||
) &&
|
) &&
|
||||||
(cd sub_alt &&
|
(cd sub_alt &&
|
||||||
sha1_before=$(git rev-parse --short HEAD)
|
sha1_before=$(git rev-parse --short HEAD) &&
|
||||||
echo b >b &&
|
echo b >b &&
|
||||||
git add b &&
|
git add b &&
|
||||||
git commit -m b &&
|
git commit -m b &&
|
||||||
|
@ -721,7 +721,7 @@ test_expect_success 'given commit' '
|
|||||||
test_expect_success 'setup .git file for sm2' '
|
test_expect_success 'setup .git file for sm2' '
|
||||||
(cd sm2 &&
|
(cd sm2 &&
|
||||||
REAL="$(pwd)/../.real" &&
|
REAL="$(pwd)/../.real" &&
|
||||||
mv .git "$REAL"
|
mv .git "$REAL" &&
|
||||||
echo "gitdir: $REAL" >.git)
|
echo "gitdir: $REAL" >.git)
|
||||||
'
|
'
|
||||||
|
|
||||||
|
@ -27,6 +27,6 @@ test_expect_success 'setup' \
|
|||||||
|
|
||||||
test_expect_success \
|
test_expect_success \
|
||||||
'check if contextually independent diffs for the same file apply' \
|
'check if contextually independent diffs for the same file apply' \
|
||||||
'( git diff test~2 test~1; git diff test~1 test~0 )| git apply'
|
'( git diff test~2 test~1 && git diff test~1 test~0 )| git apply'
|
||||||
|
|
||||||
test_done
|
test_done
|
||||||
|
Loading…
Reference in New Issue
Block a user