summaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2009-04-01 22:49:24 -0700
committerJunio C Hamano <gitster@pobox.com>2009-04-01 22:49:24 -0700
commit37a13acb2e9ec58c9dd8ee81a48dd4fa6d90ff29 (patch)
treec7496f349137603a8ef89cb72b9049107b84e04a /t
parent85b7bd50c47e0f5236cdb93d1be3163a8a1a3be6 (diff)
parentd7d9c2d04962b5aec34ec891d82dd74262306c56 (diff)
downloadgit-37a13acb2e9ec58c9dd8ee81a48dd4fa6d90ff29.tar.gz
Merge branch 'mh/format-patch-add-header'
* mh/format-patch-add-header: format-patch: add arbitrary email headers
Diffstat (limited to 't')
-rwxr-xr-xt/t4014-format-patch.sh15
1 files changed, 15 insertions, 0 deletions
diff --git a/t/t4014-format-patch.sh b/t/t4014-format-patch.sh
index f187d15e32..11061ddd5b 100755
--- a/t/t4014-format-patch.sh
+++ b/t/t4014-format-patch.sh
@@ -128,6 +128,21 @@ test_expect_success 'additional command line cc' '
grep "^ *S. E. Cipient <scipient@example.com>$" patch5
'
+test_expect_success 'command line headers' '
+
+ git config --unset-all format.headers &&
+ git format-patch --add-header="Cc: R. E. Cipient <rcipient@example.com>" --stdout master..side | sed -e "/^$/q" >patch6 &&
+ grep "^Cc: R. E. Cipient <rcipient@example.com>$" patch6
+'
+
+test_expect_success 'configuration headers and command line headers' '
+
+ git config --replace-all format.headers "Cc: R. E. Cipient <rcipient@example.com>" &&
+ git format-patch --add-header="Cc: S. E. Cipient <scipient@example.com>" --stdout master..side | sed -e "/^$/q" >patch7 &&
+ grep "^Cc: R. E. Cipient <rcipient@example.com>,$" patch7 &&
+ grep "^ *S. E. Cipient <scipient@example.com>$" patch7
+'
+
test_expect_success 'multiple files' '
rm -rf patches/ &&