1 #Test if MIME convertion work
5 draft="$MH_TEST_DIR/send-$$.draft"
7 profile="$MMH/profile-send"
9 cat "`mhparam profile`" - >"$profile" <<!
10 default-from: Bob <bob@example.org>
13 export MMHP="$profile"
16 From: Bob <bob@example.org>
18 Date: Sun, 25 Oct 2015 18:59:56 +0100
24 runandcheck 'send -debug "$draft" | sed "/^Content-ID/s/:.*/: <TESTID>/"' <<!
25 From: Bob <bob@example.org>
27 Date: Sun, 25 Oct 2015 18:59:56 +0100
30 Content-Type: text/plain; charset="us-ascii"
39 From: Bob <bob@example.org>
41 Date: Sun, 25 Oct 2015 18:59:56 +0100
44 Content-Type: text/plain; charset="us-ascii"
50 runandcheck 'send -debug "$draft"' <<!
51 From: Bob <bob@example.org>
53 Date: Sun, 25 Oct 2015 18:59:56 +0100
56 Content-Type: text/plain; charset="us-ascii"
69 Date: Fri, 05 Aug 2016 21:38:40 +0200
73 runandcheck 'send -debug "$draft" | sed "/^Content-ID/s/:.*/: <TESTID>/"' <<!
76 Date: Fri, 05 Aug 2016 21:38:40 +0200
78 Content-Type: text/plain; charset="us-ascii"
80 From: Bob <bob@example.org>
91 Date: Fri, 05 Aug 2016 21:38:56 +0200
96 runandcheck 'send -debug "$draft" | sed "/^Content-ID/s/:.*/: <TESTID>/"' <<!
99 Date: Fri, 05 Aug 2016 21:38:56 +0200
101 Content-Type: text/plain; charset="UTF-8"
103 Content-Transfer-Encoding: quoted-printable
104 From: Bob <bob@example.org>
117 Content-Type: text/plain; charset="us-ascii"
118 Date: Fri, 05 Aug 2016 21:42:16 +0200
122 runandcheck 'send -debug "$draft" | sed "/^Content-ID/s/:.*/: <TESTID>/"' <<!
126 Content-Type: text/plain; charset="us-ascii"
127 Date: Fri, 05 Aug 2016 21:42:16 +0200
128 From: Bob <bob@example.org>
140 Content-Type: text/html; charset="us-ascii"
141 Date: Fri, 05 Aug 2016 21:43:06 +0200
145 runandcheck 'send -debug "$draft"' <<!
149 Content-Type: text/html; charset="us-ascii"
150 Date: Fri, 05 Aug 2016 21:43:06 +0200
151 From: Bob <bob@example.org>
163 Content-Type: text/plain; charset="latin1"
164 Date: Fri, 05 Aug 2016 21:44:00 +0200
168 runandcheck 'send -debug "$draft"' <<!
172 Content-Type: text/plain; charset="latin1"
173 Date: Fri, 05 Aug 2016 21:44:00 +0200
174 From: Bob <bob@example.org>
182 # now something more complex with separate call to mhbuild(1)
188 Date: Fri, 05 Aug 2016 21:46:20 +0200
193 #text/plain tests/send/ulm.txt
195 #begin [Picture of an Amphioctopus marginatus] alternative
196 #image/png tests/send/amphioctopus-marginatus.png
197 Amphioctopus marginatus sitting in its portable home
198 composed of coconut shell pieces.
202 runandcheck 'mhbuild "$draft"' <<!
204 runandcheck 'mhlist -v -file "$draft"' <<!
205 msg part type/subtype size description
206 0 multipart/mixed 2623
207 boundary="----- =_aaaaaaaaaa0"
216 5 multipart/alternative 1663 Picture of an Amphioctopus marginatu
217 boundary="----- =_aaaaaaaaaa1"
224 runandcheck 'send -debug "$draft" | sed "/^Content-ID/s/:.*/: <TESTID>/"' <<!
227 Date: Fri, 05 Aug 2016 21:46:20 +0200
229 Content-Type: multipart/mixed; boundary="----- =_aaaaaaaaaa0"
231 From: Bob <bob@example.org>
233 ------- =_aaaaaaaaaa0
234 Content-Type: text/plain; charset="us-ascii"
239 ------- =_aaaaaaaaaa0
240 Content-Type: text/html; charset="us-ascii"
245 ------- =_aaaaaaaaaa0
246 Content-Type: text/plain; charset="us-ascii"
249 in ulm und um ulm und um ulm herum
251 ------- =_aaaaaaaaaa0
252 Content-Type: text/plain; charset="UTF-8"
254 Content-Transfer-Encoding: quoted-printable
258 ------- =_aaaaaaaaaa0
259 Content-Type: multipart/alternative; boundary="----- =_aaaaaaaaaa1"
261 Content-Description: Picture of an Amphioctopus marginatus
263 ------- =_aaaaaaaaaa1
264 Content-Type: image/png
266 Content-Transfer-Encoding: base64
268 iVBORw0KGgoAAAANSUhEUgAAADIAAAArBAMAAADIyMbRAAAABGdBTUEAALGPC/xhBQA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+qh1F0ZufSgAAACV0RVh0ZGF0
283 ZTpjcmVhdGUAMjAxNi0wOC0xMFQxODo0MTo1NyswMjowMDnWAU8AAAAldEVYdGRhdGU6bW9kaWZ5
284 ADIwMTYtMDgtMTBUMTg6NDE6NTcrMDI6MDBIi7nzAAAAAElFTkSuQmCC
286 ------- =_aaaaaaaaaa1
287 Content-Type: text/plain; charset="us-ascii"
290 Amphioctopus marginatus sitting in its portable home
291 composed of coconut shell pieces.
293 ------- =_aaaaaaaaaa1--
295 ------- =_aaaaaaaaaa0
296 Content-Type: text/plain; charset="us-ascii"
301 ------- =_aaaaaaaaaa0--