From: Derrick Stolee Date: Wed, 12 Sep 2018 14:31:03 +0000 (-0700) Subject: t3206-range-diff.sh: cover single-patch case X-Git-Tag: v2.20.0-rc0~222^2 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/cdc067c3197f659470591c1d5614cf9221a43c98 t3206-range-diff.sh: cover single-patch case The commit 40ce4160 "format-patch: allow --range-diff to apply to a lone-patch" added the ability to see a range-diff as commentary after the commit message of a single patch series (i.e. [PATCH] instead of [PATCH X/N]). However, this functionality was not covered by a test case. Add a simple test case that checks that a range-diff is written as commentary to the patch. Signed-off-by: Derrick Stolee Signed-off-by: Junio C Hamano --- diff --git a/t/t3206-range-diff.sh b/t/t3206-range-diff.sh index 3d7a2d8a4d..6babc0e276 100755 --- a/t/t3206-range-diff.sh +++ b/t/t3206-range-diff.sh @@ -154,4 +154,9 @@ do ' done +test_expect_success 'format-patch --range-diff as commentary' ' + git format-patch --stdout --range-diff=HEAD~1 HEAD~1 >actual && + test_i18ngrep "^Range-diff:$" actual +' + test_done