From: Matt Graham Date: Sat, 16 May 2009 03:10:19 +0000 (-0400) Subject: Splitting a hunk that adds a line at the top fails in "add -p" X-Git-Tag: v1.6.3.2~8^2~2 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=f67182bf65b01290a9544e9599ea8255e657e567;p=git.git Splitting a hunk that adds a line at the top fails in "add -p" Splitting a hunk into two in add -p doesn't work for a diff that adds a new line at the top of the file with other add in the same hunk. Signed-off-by: Matthew Graham Signed-off-by: Junio C Hamano --- diff --git a/t/t3701-add-interactive.sh b/t/t3701-add-interactive.sh index dfc65601a..9999fcd4b 100755 --- a/t/t3701-add-interactive.sh +++ b/t/t3701-add-interactive.sh @@ -165,4 +165,36 @@ test_expect_success FILEMODE 'stage mode but not hunk' ' # end of tests disabled when filemode is not usable +# Write the patch file with a new line at the top and bottom +cat >patch <expected < diff && + test_cmp expected diff +' + test_done