summaryrefslogtreecommitdiff
path: root/ext/iconv/tests/bug53891.phpt
blob: 342b48e3a22b99320cd574f1df3207a8f71e0c68 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
--TEST--
Bug #53891 (iconv_mime_encode() fails to Q-encode UTF-8 string)
--SKIPIF--
<?php
if (!extension_loaded('iconv')) die('skip iconv extension not available');
?>
--FILE--
<?php
$preferences = array(
    'scheme' => 'Q',
    'input-charset'  => 'utf-8',
    'output-charset' => 'utf-8',
    'line-length' => 74,
    'line-break-chars' => "\r\n",
);
var_dump(iconv_mime_encode('subject', "d obeybiubrsfqllpdtpge…", $preferences));
?>
===DONE===
--EXPECT--
string(54) "subject: =?utf-8?Q?d=20obeybiubrsfqllpdtpge=E2=80=A6?="
===DONE===