Mercurial > hg > rc1
diff vendor/pear/mail_mime/tests/test_Bug_7561_1.phpt @ 0:1e000243b222
vanilla 1.3.3 distro, I hope
author | Charlie Root |
---|---|
date | Thu, 04 Jan 2018 15:50:29 -0500 |
parents | |
children |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/vendor/pear/mail_mime/tests/test_Bug_7561_1.phpt Thu Jan 04 15:50:29 2018 -0500 @@ -0,0 +1,24 @@ +--TEST-- +Bug #7561 Mail_mimePart::quotedPrintableEncode() misbehavior with mbstring overload +--INI-- +mbstring.language=Neutral +mbstring.func_overload=6 +mbstring.internal_encoding=UTF-8 +mbstring.http_output=UTF-8 +--SKIPIF-- +<?php +include "PEAR.php"; +if (!extension_loaded('mbstring')){ + if (!PEAR::loadExtension('mbstring')){ + print('SKIP could not load mbstring module'); + } +} +--FILE-- +<?php +include("Mail/mimePart.php"); +// string is UTF-8 encoded +$input = "Micha\xC3\xABl \xC3\x89ric St\xC3\xA9phane"; +$rv = Mail_mimePart::quotedPrintableEncode($input, 76, "\n"); +echo $rv, "\n"; +--EXPECT-- +Micha=C3=ABl =C3=89ric St=C3=A9phane