rebase: implement --[no-]autostash and rebase.autostash
[gitweb.git] / t / t7612-merge-verify-signatures.sh
index 6ccfbf367aa2b52e9fdb42ade6b23b0292171715..21a0bf8fb8c4946f625b317a9d60aa05bb0acb65 100755 (executable)
@@ -27,6 +27,10 @@ test_expect_success GPG 'create signed commits' '
        git hash-object -w -t commit forged >forged.commit &&
        git checkout initial &&
 
+       git checkout -b side-untrusted &&
+       echo 3 >baz && git add baz &&
+       test_tick && git commit -SB7227189 -m "untrusted on side"
+
        git checkout master
 '
 
@@ -40,6 +44,11 @@ test_expect_success GPG 'merge commit with bad signature with verification' '
        test_i18ngrep "has a bad GPG signature" mergeerror
 '
 
+test_expect_success GPG 'merge commit with untrusted signature with verification' '
+       test_must_fail git merge --ff-only --verify-signatures side-untrusted 2>mergeerror &&
+       test_i18ngrep "has an untrusted GPG signature" mergeerror
+'
+
 test_expect_success GPG 'merge signed commit with verification' '
        git merge --verbose --ff-only --verify-signatures side-signed >mergeoutput &&
        test_i18ngrep "has a good GPG signature" mergeoutput