chiark / gitweb /
Import curl_7.56.1.orig.tar.gz
[curl.git] / tests / data / test648
1 <testcase>
2 <info>
3 <keywords>
4 SMTP
5 MULTIPART
6 </keywords>
7 </info>
8
9 #
10 # Server-side
11 <reply>
12 </reply>
13
14 #
15 # Client-side
16 <client>
17 <server>
18 smtp
19 </server>
20  <name>
21 SMTP multipart with transfer content encoders
22  </name>
23 <stdin>
24 From: different\r
25 To: another\r
26 \r
27 body\r
28 </stdin>
29  <command>
30 smtp://%HOSTIP:%SMTPPORT/648 --mail-rcpt recipient@example.com --mail-from sender@example.com -F '=This is the e-mail inline text with a very long line containing the special character = and that should be split by encoder.;headers=Content-disposition: "inline";encoder=quoted-printable' -F "=@log/test648.txt;encoder=base64" -H "From: different" -H "To: another"
31 </command>
32 <file name="log/test648.txt">
33 This is an attached file.
34
35 It may contain any type of data and will be encoded in base64 for transfer.
36 </file>
37 </client>
38
39 #
40 # Verify data after the test has been "shot"
41 <verify>
42 <strippart>
43 s/^--------------------------[a-z0-9]*/------------------------------/
44 s/boundary=------------------------[a-z0-9]*/boundary=----------------------------/
45 </strippart>
46 <protocol>
47 EHLO 648\r
48 MAIL FROM:<sender@example.com>\r
49 RCPT TO:<recipient@example.com>\r
50 DATA\r
51 QUIT\r
52 </protocol>
53 <upload>
54 Content-Type: multipart/mixed; boundary=----------------------------\r
55 Mime-Version: 1.0\r
56 From: different\r
57 To: another\r
58 \r
59 ------------------------------\r
60 Content-Transfer-Encoding: quoted-printable\r
61 Content-disposition: "inline"\r
62 \r
63 This is the e-mail inline text with a very long line containing the special=\r
64  character =3D and that should be split by encoder.\r
65 ------------------------------\r
66 Content-Disposition: attachment; filename="test648.txt"\r
67 Content-Transfer-Encoding: base64\r
68 \r
69 VGhpcyBpcyBhbiBhdHRhY2hlZCBmaWxlLgoKSXQgbWF5IGNvbnRhaW4gYW55IHR5cGUgb2YgZGF0\r
70 YSBhbmQgd2lsbCBiZSBlbmNvZGVkIGluIGJhc2U2NCBmb3IgdHJhbnNmZXIuCg==\r
71 --------------------------------\r
72 .\r
73 </upload>
74 </verify>
75 </testcase>