Code

perl/Makefile: install Git::I18N under NO_PERL_MAKEMAKER
[git.git] / t / t7600-merge.sh
index 5d8c428543bd61a27489af72045b4e1816d240e9..9e27bbf902e275671cb80310630a8bedcaab353c 100755 (executable)
@@ -27,6 +27,7 @@ Testing basic merge operations/option parsing.
 '
 
 . ./test-lib.sh
+. "$TEST_DIRECTORY"/lib-gpg.sh
 
 printf '%s\n' 1 2 3 4 5 6 7 8 9 >file
 printf '%s\n' '1 X' 2 3 4 5 6 7 8 9 >file.1
@@ -670,4 +671,28 @@ test_expect_success 'merge --no-ff --edit' '
        test_cmp actual expected
 '
 
+test_expect_success GPG 'merge --ff-only tag' '
+       git reset --hard c0 &&
+       git commit --allow-empty -m "A newer commit" &&
+       git tag -s -m "A newer commit" signed &&
+       git reset --hard c0 &&
+
+       git merge --ff-only signed &&
+       git rev-parse signed^0 >expect &&
+       git rev-parse HEAD >actual &&
+       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
+'
+
 test_done