summaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <gitster@pobox.com>2017-06-26 14:09:31 -0700
committerLibravatar Junio C Hamano <gitster@pobox.com>2017-06-26 14:09:31 -0700
commit54e6ce5960689026f1ea97db493dc8cd0a7f8e1e (patch)
tree504f97bb1425d2f9ff1603be45130487a6355c44 /t
parentMerge branch 'dt/raise-core-packed-git-limit' (diff)
parentadd--interactive: quote commentChar regex (diff)
downloadtgif-54e6ce5960689026f1ea97db493dc8cd0a7f8e1e.tar.xz
Merge branch 'jk/add-p-commentchar-fix'
"git add -p" were updated in 2.12 timeframe to cope with custom core.commentchar but the implementation was buggy and a metacharacter like $ and * did not work. * jk/add-p-commentchar-fix: add--interactive: quote commentChar regex add--interactive: handle EOF in prompt_yesno
Diffstat (limited to 't')
-rwxr-xr-xt/t3701-add-interactive.sh8
1 files changed, 8 insertions, 0 deletions
diff --git a/t/t3701-add-interactive.sh b/t/t3701-add-interactive.sh
index 2ecb43a616..2f3e7cea64 100755
--- a/t/t3701-add-interactive.sh
+++ b/t/t3701-add-interactive.sh
@@ -477,4 +477,12 @@ test_expect_success 'add -p does not expand argument lists' '
! grep not-changed trace.out
'
+test_expect_success 'hunk-editing handles custom comment char' '
+ git reset --hard &&
+ echo change >>file &&
+ test_config core.commentChar "\$" &&
+ echo e | GIT_EDITOR=true git add -p &&
+ git diff --exit-code
+'
+
test_done