Added release note that ./@ is obsolete/deprecated.
[mmh] / test / post / test-post-multiple
1 #!/bin/sh
2 #
3 # Test the behavior of post with multiple recipients
4 #
5
6 set -e
7
8 if test -z "${MH_OBJ_DIR}"; then
9     srcdir=`dirname "$0"`/../..
10     MH_OBJ_DIR=`cd "$srcdir" && pwd`; export MH_OBJ_DIR
11 fi
12
13 . "${srcdir}/test/post/test-post-common.sh"
14
15 #
16 # Multiple recipients test
17 #
18 cat > "${MH_TEST_DIR}/Mail/draft" <<EOF
19 From: Mr Nobody <nobody@example.com>
20 To: Somebody One <somebody1@example.com>,
21     Somebody Two <somebody2@example.com>
22 Subject: Test multiple
23
24 This is test of multiple recipients.
25 EOF
26
27 cat > "${testname}.expected" <<EOF
28 EHLO nosuchhost.example.com
29 MAIL FROM:<nobody@example.com>
30 RCPT TO:<somebody1@example.com>
31 RCPT TO:<somebody2@example.com>
32 DATA
33 From: Mr Nobody <nobody@example.com>
34 To: Somebody One <somebody1@example.com>,
35     Somebody Two <somebody2@example.com>
36 Subject: Test multiple
37 Date:
38
39 This is test of multiple recipients.
40 .
41 QUIT
42 EOF
43
44 test_post "${testname}.actual" "${testname}.expected"
45
46 exit ${failed:-0}