summaryrefslogtreecommitdiff
path: root/t/t9001-send-email.sh
AgeCommit message (Collapse)AuthorFilesLines
2008-03-13add test_cmp function for test scriptsLibravatar Jeff King1-1/+1
Many scripts compare actual and expected output using "diff -u". This is nicer than "cmp" because the output shows how the two differ. However, not all versions of diff understand -u, leading to unnecessary test failure. This adds a test_cmp function to the test scripts and switches all "diff -u" invocations to use it. The function uses the contents of "$GIT_TEST_CMP" to compare its arguments; the default is "diff -u". On systems with a less-capable diff, you can do: GIT_TEST_CMP=cmp make test Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-02-24send-email: test compose functionalityLibravatar Jeff King1-0/+29
This is just a basic sanity check that --compose works at all. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-02-24t9001: enhance fake sendmail test harnessLibravatar Jeff King1-7/+15
Previously, the fake.sendmail test harness would write its output to a hardcoded file, allowing only a single message to be tested. Instead, let's have it save the messages for all of its invocations so that we can see which messages were sent, and in which order. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-02-21send-email: fix In-Reply-To regressionLibravatar Jay Soffian1-0/+21
Fix a regression introduced by 1ca3d6e (send-email: squelch warning due to comparing undefined $_ to "") where if the user was prompted for an initial In-Reply-To and didn't provide one, messages would be sent out with an invalid In-Reply-To of "<>" Also add test cases for the regression and the fix. A small modification was needed to allow send-email to take its replies from stdin if the environment variable GIT_SEND_EMAIL_NOTTY is set. Signed-off-by: Jay Soffian <jaysoffian@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-01-28t9001: add missing && operatorsLibravatar Jeff King1-4/+4
The exit value of some commands was not being used for the test output. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-01-18send-email: add no-validate optionLibravatar Jeff King1-0/+10
Since we are now sanity-checking the contents of patches and refusing to send ones with long lines, this knob provides a way for the user to override the new behavior (if, e.g., he knows his SMTP path will handle it). Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-01-18send-email: validate patches before sending anythingLibravatar Jeff King1-0/+20
We try to catch errors early so that we don't end up sending half of a broken patch series. Right now the only validation is checking that line-lengths are under the SMTP-mandated limit of 998. The validation parsing is very crude (it just checks each line length without understanding the mailbox format) but should work fine for this simple check. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-11-19git-send-email: show all headers when sending mailLibravatar David D. Kilzer1-0/+37
As a git newbie, it was confusing to set an In-Reply-To header but then not see it printed when the git-send-email command was run. This patch prints all headers that would be sent to sendmail or an SMTP server instead of only printing From, Subject, Cc, To. It also removes the now-extraneous Date header after the "Log says" line. Added test to t/t9001-send-email.sh. Signed-off-by: David D. Kilzer <ddkilzer@kilzer.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-09-24Fixed minor typo in t/t9001-send-email.sh test command line.Libravatar Glenn Rempe1-1/+1
The git-send-email command line in the test was missing a single hyphen. Signed-off-by: Glenn Rempe <glenn@rempe.us> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2006-07-03send-email: do not barf when Term::ReadLine does not like your terminalLibravatar Junio C Hamano1-4/+7
As long as we do not need to readline from the terminal, we should not barf when starting up the program. Without this patch, t9001 test on Cygwin occasionally died with the following error message: Unable to get Terminal Size. The TIOCGWINSZ ioctl didn't work. The COLUMNS and LINES environment variables didn't work. The resize program didn't work. at /usr/lib/perl5/vendor_perl/5.8/cygwin/Term/ReadKey.pm line 362. Compilation failed in require at /usr/lib/perl5/vendor_perl/5.8/Term/ReadLine/Perl.pm line 58. Acked-by: Ryan Anderson <ryan@michonline.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-30send-email: do not pass bogus address to local sendmail binaryLibravatar Junio C Hamano1-6/+13
This makes t9001 test happy. Also fixes the warning on uninitialized $references variable again. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-05-29Add a basic test case for git send-email, and fix some real bugs discovered.Libravatar Ryan Anderson1-0/+34
Signed-off-by: Ryan Anderson <rda@google.com> Signed-off-by: Junio C Hamano <junkio@cox.net>