aboutsummaryrefslogtreecommitdiffstats
path: root/t
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2021-11-04 12:07:46 -0700
committerJunio C Hamano <gitster@pobox.com>2021-11-04 12:07:46 -0700
commita876f0b95c95d58436045454ea7c8b51c5f96c2e (patch)
tree70b1f2fdee58f4f561b8ef7baa98270ead83005b /t
parent876b1423317071f43c99666f3fc3db3642dfbe14 (diff)
parent47bfdfb3fd3b4752d2292a6744fae9abe37b8f1e (diff)
downloadgit-a876f0b95c95d58436045454ea7c8b51c5f96c2e.tar.gz
Merge branch 'ar/fix-git-pull-no-verify'
"git pull --no-verify" did not affect the underlying "git merge". * ar/fix-git-pull-no-verify: pull: honor --no-verify and do not call the commit-msg hook
Diffstat (limited to 't')
-rwxr-xr-xt/t5521-pull-options.sh24
1 files changed, 24 insertions, 0 deletions
diff --git a/t/t5521-pull-options.sh b/t/t5521-pull-options.sh
index 7601c919fd..66cfcb09c5 100755
--- a/t/t5521-pull-options.sh
+++ b/t/t5521-pull-options.sh
@@ -228,4 +228,28 @@ test_expect_success 'git pull --no-signoff flag cancels --signoff flag' '
test_must_be_empty actual
'
+test_expect_success 'git pull --no-verify flag passed to merge' '
+ test_when_finished "rm -fr src dst actual" &&
+ git init src &&
+ test_commit -C src one &&
+ git clone src dst &&
+ write_script dst/.git/hooks/commit-msg <<-\EOF &&
+ false
+ EOF
+ test_commit -C src two &&
+ git -C dst pull --no-ff --no-verify
+'
+
+test_expect_success 'git pull --no-verify --verify passed to merge' '
+ test_when_finished "rm -fr src dst actual" &&
+ git init src &&
+ test_commit -C src one &&
+ git clone src dst &&
+ write_script dst/.git/hooks/commit-msg <<-\EOF &&
+ false
+ EOF
+ test_commit -C src two &&
+ test_must_fail git -C dst pull --no-ff --no-verify --verify
+'
+
test_done