forked from mirror/django-mailbox
Adding tests and minor code changes to ensure that we properly handle the distinction between bytes and text when dehydrating/rehydrating messages.
This commit is contained in:
parent
3ee4b43936
commit
adb17e7d67
5 changed files with 109 additions and 24 deletions
|
|
@ -7,8 +7,7 @@ Message-ID: <CAMdmm+hGH8Dgn-_0xnXJCd=PhyNAiouOYm5zFP0z-foqTO60zA@mail.gmail.com>
|
|||
Subject: Message Without Attachment
|
||||
From: Adam Coddington <test@adamcoddington.net>
|
||||
To: Adam Coddington <test@adamcoddington.net>
|
||||
Content-Type: text/plain;
|
||||
charset="iso-8859-1"
|
||||
Content-Type: text/plain; charset="iso-8859-1"
|
||||
Content-Transfer-Encoding: 7bit
|
||||
|
||||
Hello there.
|
||||
|
|
|
|||
|
|
@ -0,0 +1,9 @@
|
|||
Date: Fri, 30 Jan 2012 11:30:01 PST
|
||||
Subject: Tjest
|
||||
From: "Somebody" <somebody@somewhere.com>
|
||||
To: idontknow@somewhere.com
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset="us-ascii"
|
||||
Content-Transfer-Encoding: 7bit
|
||||
|
||||
Ýòî ñîîáùåíèå èìååò íåïðàâèëüíóþ êîäèðîâêà.
|
||||
|
|
@ -0,0 +1,9 @@
|
|||
Date: Fri, 30 Jan 2012 11:30:01 PST
|
||||
Subject: Tjest
|
||||
From: "Somebody" <somebody@somewhere.com>
|
||||
To: idontknow@somewhere.com
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset="raspberries"
|
||||
Content-Transfer-Encoding: 7bit
|
||||
|
||||
Это сообщение имеет неверная кодировка.
|
||||
Loading…
Add table
Add a link
Reference in a new issue