-test_expect_success 'prepare repository' \
- 'echo AIT >a && echo BIT >b && echo CIT >c && echo DIT >d &&
+test_expect_success 'prepare repository' '
+ echo AIT >a && echo BIT >b && echo CIT >c && echo DIT >d &&
# apply needs to be able to skip the binary material correctly
# in order to report the line number of a corrupt patch.
# apply needs to be able to skip the binary material correctly
# in order to report the line number of a corrupt patch.
-test_expect_success 'apply detecting corrupt patch correctly' \
- 'git diff | sed -e 's/-CIT/xCIT/' >broken &&
+test_expect_success 'apply detecting corrupt patch correctly' '
+ git diff | sed -e 's/-CIT/xCIT/' >broken &&
detected=`cat detected` &&
detected=`expr "$detected" : "fatal.*at line \\([0-9]*\\)\$"` &&
detected=`sed -ne "${detected}p" broken` &&
detected=`cat detected` &&
detected=`expr "$detected" : "fatal.*at line \\([0-9]*\\)\$"` &&
detected=`sed -ne "${detected}p" broken` &&
-test_expect_success 'apply detecting corrupt patch correctly' \
- 'git diff --binary | sed -e 's/-CIT/xCIT/' >broken &&
+test_expect_success 'apply detecting corrupt patch correctly' '
+ git diff --binary | sed -e 's/-CIT/xCIT/' >broken &&
detected=`cat detected` &&
detected=`expr "$detected" : "fatal.*at line \\([0-9]*\\)\$"` &&
detected=`sed -ne "${detected}p" broken` &&
detected=`cat detected` &&
detected=`expr "$detected" : "fatal.*at line \\([0-9]*\\)\$"` &&
detected=`sed -ne "${detected}p" broken` &&
test_expect_success 'initial commit' 'git commit -a -m initial'
# Try removal (b), modification (d), and creation (e).
test_expect_success 'initial commit' 'git commit -a -m initial'
# Try removal (b), modification (d), and creation (e).
-test_expect_success 'diff-index with --binary' \
- 'echo AIT >a && mv b e && echo CIT >c && cat e >d &&
+test_expect_success 'diff-index with --binary' '
+ echo AIT >a && mv b e && echo CIT >c && cat e >d &&
git update-index --add --remove a b c d e &&
tree0=`git write-tree` &&
git diff --cached --binary >current &&
git update-index --add --remove a b c d e &&
tree0=`git write-tree` &&
git diff --cached --binary >current &&