diff options
author | uckelman <uckelman@nomic.net> | 2010-11-25 12:09:52 +0000 |
---|---|---|
committer | uckelman <uckelman@nomic.net> | 2010-11-25 12:09:52 +0000 |
commit | 8fce94b07f795cc5ea2ec31938d4ac1066eb022d (patch) | |
tree | 86b4cf039fd7282b2f83dbbcae0fc864c78ef90a /test/build_email_test.php | |
parent | ba56609798b023768410c3ada7f9784c5e150ac7 (diff) |
* Broke out From construction.
* Fixed RFC822 quoting bug.
git-svn-id: https://vassalengine.svn.sourceforge.net/svnroot/vassalengine/site-src/trunk@7499 67b53d14-2c14-4ace-a08f-0dab2b34000c
Diffstat (limited to 'test/build_email_test.php')
-rw-r--r-- | test/build_email_test.php | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/test/build_email_test.php b/test/build_email_test.php index c78ab7b..225e30f 100644 --- a/test/build_email_test.php +++ b/test/build_email_test.php @@ -32,6 +32,27 @@ http://www.example.com/viewtopic.php?p=42#p42", ); } + public function test_build_from_nonascii() { + $this->assertEquals( + '=?UTF-8?B?SGVpesO2bHLDvGNrc3Rvw59hYmTDpG1wZnVuZw==?= <foo@example.com>'; + build_from('Heizölrückstoßabdämpfung', 'foo@example.com') + ); + } + + public function test_build_from_ascii() { + $this->assertEquals( + 'Joel Uckelman <uckelman@nomic.net>', + build_from('Joel Uckelman', 'uckelman@nomic.net') + ); + } + + public function test_build_from_rfc822_specials() { + $this->assertEquals( + '"L.Tankersley" <leland53@comcast.net>', + build_from('L.Tankersley', 'leland53@comcast.net') + ); + } + protected $default_headers = array( 'To' => 'messages@vassalengine.org', 'From' => 'Joel Uckelman <uckelman@nomic.net>', |