]>
diplodocus.org Git - nmh/blob - test/mhbuild/test-cte
2 #########################################################
4 # Test the use of explicit Content-Transfer-Encoding tags
6 #########################################################
8 if test -z "${MH_OBJ_DIR}"; then
9 srcdir
=`dirname "$0"`/..
/..
10 MH_OBJ_DIR
=`cd "$srcdir" && pwd`; export MH_OBJ_DIR
13 .
"$MH_OBJ_DIR/test/common.sh"
17 LC_ALL
=en_US.UTF-8
; export LC_ALL
19 draft
="$MH_TEST_DIR/$$.draft"
20 expected
="$MH_TEST_DIR/$$.expected"
23 # Force some text to be quoted-printable
27 To: Mr Test <mrtest@example.com>
32 This is a test of a message with a shørt line.
35 run_prog mhbuild
"$draft"
37 cat > "$expected" <<EOF
38 To: Mr Test <mrtest@example.com>
42 Content-Type: text/plain; charset="UTF-8"
43 Content-Transfer-Encoding: quoted-printable
45 This is a test of a message with a sh=C3=B8rt line.
49 # Force some text to be base64
53 To: Mr Test <mrtest@example.com>
58 This is a test of a message with a shørt line.
61 run_prog mhbuild
"$draft"
63 cat > "$expected" <<EOF
64 To: Mr Test <mrtest@example.com>
68 Content-Type: text/plain; charset="UTF-8"
69 Content-Transfer-Encoding: base64
71 VGhpcyBpcyBhIHRlc3Qgb2YgYSBtZXNzYWdlIHdpdGggYSBzaMO4cnQgbGluZS4NCg==
74 check
"$draft" "$expected"