2
0
forked from Wavyzz/dolibarr

NEW #5896 More complete data on event sent by email (name in title,

emails list in details)
This commit is contained in:
Laurent Destailleur
2016-10-24 02:02:30 +02:00
parent 6b67e69412
commit b284bdd953
4 changed files with 51 additions and 18 deletions

View File

@@ -177,7 +177,22 @@ class CMailFileTest extends PHPUnit_Framework_TestCase
$result=$localobject->getValidAddress($src,3,1);
print __METHOD__." result=".$result."\n";
$this->assertEquals($result,'"=?UTF-8?B?Sm9obiBEb2U=?=" <john@doe.com>');
$src='John Doe <john@doe.com>';
$result=$localobject->getValidAddress($src,4);
print __METHOD__." result=".$result."\n";
$this->assertEquals($result,'John Doe');
$src='John Doe <john@doe.com>, John Doe2 <john@doe3.com>, John Doe3 <john@doe2.com>';
$result=$localobject->getValidAddress($src,4);
print __METHOD__." result=".$result."\n";
$this->assertEquals($result,'John Doe,John Doe2,John Doe3');
$src='John Doe <john@doe.com>, John Doe2 <john@doe3.com>, John Doe3 <john@doe2.com>';
$result=$localobject->getValidAddress($src,4,0,2);
print __METHOD__." result=".$result."\n";
$this->assertEquals($result,'John Doe,John Doe2...');
return $result;
}