sequencer (rebase -i): skip some revert/cherry-pick specific code path
[gitweb.git] / t / t5100-mailinfo.sh
index 56988b7116e7d3951f53ddb202570af2ea60a09e..7171f67539bfafcb17d2d2fcb2f4ba4856c1131c 100755 (executable)
@@ -13,7 +13,7 @@ test_expect_success 'split sample box' \
        'git mailsplit -o. "$DATA/sample.mbox" >last &&
        last=$(cat last) &&
        echo total is $last &&
-       test $(cat last) = 17'
+       test $(cat last) = 18'
 
 check_mailinfo () {
        mail=$1 opt=$2
@@ -144,4 +144,31 @@ test_expect_success 'mailinfo unescapes with --mboxrd' '
        test_cmp expect mboxrd/msg
 '
 
+test_expect_success 'mailinfo handles rfc2822 quoted-string' '
+       mkdir quoted-string &&
+       git mailinfo /dev/null /dev/null <"$DATA/quoted-string.in" \
+               >quoted-string/info &&
+       test_cmp "$DATA/quoted-string.expect" quoted-string/info
+'
+
+test_expect_success 'mailinfo handles rfc2822 comment' '
+       mkdir comment &&
+       git mailinfo /dev/null /dev/null <"$DATA/comment.in" \
+               >comment/info &&
+       test_cmp "$DATA/comment.expect" comment/info
+'
+
+test_expect_success 'mailinfo with mailinfo.scissors config' '
+       test_config mailinfo.scissors true &&
+       (
+               mkdir sub &&
+               cd sub &&
+               git mailinfo ../msg0014.sc ../patch0014.sc <../0014 >../info0014.sc
+       ) &&
+       test_cmp "$DATA/msg0014--scissors" msg0014.sc &&
+       test_cmp "$DATA/patch0014--scissors" patch0014.sc &&
+       test_cmp "$DATA/info0014--scissors" info0014.sc
+'
+
+
 test_done