]>
diplodocus.org Git - nmh/blob - test/post/test-rfc6531
2 ######################################################
4 # Test SMTPUTF8 (RFC 6531) support.
6 ######################################################
10 if test -z "${MH_OBJ_DIR}"; then
11 srcdir
=`dirname $0`/..
/..
12 MH_OBJ_DIR
=`cd $srcdir && pwd`; export MH_OBJ_DIR
15 .
"${srcdir}/test/post/test-post-common.sh"
18 mhl
="${MH_LIBEXEC_DIR}/mhl"
20 #### Make sure that html-to-text conversion is what we expect.
21 require_locale en_US.utf
-8 en_US.utf8
22 LC_ALL
=en_US.UTF
-8; export LC_ALL
24 #### Enable EAI in mhbuild, via the profile.
25 sed "s%^\(mhbuild: .*\)%\1 -headerencoding utf-8%" "$MH" >"$MH.new"
28 # check SMTPUTF8 basic
29 start_test
'SMTPUTF8 basic'
31 cat > "${testname}.expected" <<EOF
32 EHLO nosuchhost.example.com
33 MAIL FROM:<senderø@example.com> BODY=8BITMIME SMTPUTF8
34 RCPT TO:<recipientæ@example.com>
36 From: senderø@example.com
37 To: recipientæ@example.com
38 Subject: Blåbærsyltetøy
40 Content-Type: text/plain; charset="UTF-8"
41 Content-Transfer-Encoding: 8bit
44 Blåbærsyltetøy er veldig godt. Jeg liker blåbærsyltetøy.
48 Arnt Gulbrandsen and Jiankang Yao, "Email Address Internationalization",
49 Computing Edge 1:6, June 2015,
50 http://www.computer.org/cms/computing-edge/ce-jun15-final.pdf, p. 50.
55 cat > "${MH_TEST_DIR}/Mail/draft" <<EOF
56 From: senderø@example.com
57 To: recipientæ@example.com
58 Subject: Blåbærsyltetøy
60 Blåbærsyltetøy er veldig godt. Jeg liker blåbærsyltetøy.
64 Arnt Gulbrandsen and Jiankang Yao, "Email Address Internationalization",
65 Computing Edge 1:6, June 2015,
66 http://www.computer.org/cms/computing-edge/ce-jun15-final.pdf, p. 50.
69 test_post
"${testname}.actual" "${testname}.expected"