git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH v2 2/2] test/send-email: add to-cover test

From
MTMichael S. Tsirkin <mst@redhat.com>
Date
Apr 3, 2014, 18:14 UTC
Message-ID
<1396548814-27278-2-git-send-email-mst@redhat.com>
In-Reply-To
<1396548814-27278-1-git-send-email-mst@redhat.com>
Does it work? I am not sure.
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
---
 t/t9001-send-email.sh | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)
diff --git a/t/t9001-send-email.sh b/t/t9001-send-email.sh
index 3119c8c..3b17884 100755
--- a/t/t9001-send-email.sh
+++ b/t/t9001-send-email.sh
@@ -1334,6 +1334,22 @@ test_expect_success $PREREQ '--force sends cover letter template anyway' '
 	test -n "$(ls msgtxt*)"
 '
 
+test_expect_success $PREREQ 'to-cover adds To to all mail' '
+	clean_fake_sendmail &&
+	rm -fr outdir &&
+	git format-patch --cover-letter -2 -o outdir &&
+	git send-email \
+	  --force \
+	  --from="Example <nobody@example.com>" \
+	  --to=nobody@example.com \
+	  --smtp-server="$(pwd)/fake.sendmail" \
+	  outdir/0002-*.patch \
+	  outdir/0000-*.patch \
+	  outdir/0001-*.patch \
+	  2>errors >out &&
+	! grep "SUBJECT HERE" errors &&
+	test -n "$(ls msgtxt*)"
+'
 test_expect_success $PREREQ 'sendemail.aliasfiletype=mailrc' '
 	clean_fake_sendmail &&
 	echo "alias sbd  somebody@example.org" >.mailrc &&
-- 
MST
Previous: Michael S. TsirkinNext: Junio C Hamano
Message 2 of 6 in “git-send-email: two new options: to-cover, cc-cover”
  1. 1/2 git-send-email: two new options: to-cover, cc-coverMichael S. Tsirkin, Apr 3, 2014
  2. 2/2 test/send-email: add to-cover testMichael S. Tsirkin, Apr 3, 2014
  3. Junio C HamanoApr 3, 2014
  4. Junio C HamanoApr 3, 2014
  5. Michael S. TsirkinApr 27, 2014
  6. Eric SunshineApr 3, 2014

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.