summaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <gitster@pobox.com>2010-03-07 12:47:14 -0800
committerLibravatar Junio C Hamano <gitster@pobox.com>2010-03-07 12:47:14 -0800
commit93825874671ae15296442b1e7e39166c1754c934 (patch)
treee6b0eb8f73368d7388142d53491e70d1f8a9dba3 /t
parentMerge branch 'jc/maint-fix-mailinfo-strip' (diff)
parentadd-interactive: fix bogus diff header line ordering (diff)
downloadtgif-93825874671ae15296442b1e7e39166c1754c934.tar.xz
Merge branch 'jk/maint-add--interactive-delete'
* jk/maint-add--interactive-delete: add-interactive: fix bogus diff header line ordering
Diffstat (limited to 't')
-rwxr-xr-xt/t2016-checkout-patch.sh8
1 files changed, 8 insertions, 0 deletions
diff --git a/t/t2016-checkout-patch.sh b/t/t2016-checkout-patch.sh
index 4d1c2e9e09..2144184d79 100755
--- a/t/t2016-checkout-patch.sh
+++ b/t/t2016-checkout-patch.sh
@@ -66,6 +66,14 @@ test_expect_success 'git checkout -p HEAD^' '
verify_state dir/foo parent parent
'
+test_expect_success 'git checkout -p handles deletion' '
+ set_state dir/foo work index &&
+ rm dir/foo &&
+ (echo n; echo y) | git checkout -p &&
+ verify_saved_state bar &&
+ verify_state dir/foo index index
+'
+
# The idea in the rest is that bar sorts first, so we always say 'y'
# first and if the path limiter fails it'll apply to bar instead of
# dir/foo. There's always an extra 'n' to reject edits to dir/foo in