path: root/t/
diff options
authorJunio C Hamano <>2012-02-09 21:30:52 (GMT)
committerJunio C Hamano <>2012-02-09 21:30:52 (GMT)
commit3adab6f3a7793253b22a4a7aae34221d19e0236a (patch)
tree63edce038f0aa2a5256edb8a23810f562443f5e8 /t/
parentb5c9f1c1b0ed9c91463b9f46a7c9dff3efc53773 (diff)
merge: do not launch an editor on "--no-edit $tag"
When the user explicitly asked us not to, don't launch an editor. But do everything else the same way as the "edit" case, i.e. leave the comment with verification result in the log template and record the mergesig in the resulting merge commit for later inspection. Based on initiail analysis by Jonathan Nieder. Signed-off-by: Junio C Hamano <>
Diffstat (limited to 't/')
1 files changed, 12 insertions, 0 deletions
diff --git a/t/ b/t/
index a598dfa..9e27bbf 100755
--- a/t/
+++ b/t/
@@ -683,4 +683,16 @@ test_expect_success GPG 'merge --ff-only tag' '
test_cmp actual expect
+test_expect_success GPG 'merge --no-edit tag should skip editor' '
+ git reset --hard c0 &&
+ git commit --allow-empty -m "A newer commit" &&
+ git tag -f -s -m "A newer commit" signed &&
+ git reset --hard c0 &&
+ EDITOR=false git merge --no-edit signed &&
+ git rev-parse signed^0 >expect &&
+ git rev-parse HEAD^2 >actual &&
+ test_cmp actual expect