��Qc@s1ddlZddlZddlZddlmZddlmZddlmZddl m
Z
mZddlZddlm
ZddlmZd�Zyed �Wnek
r�e
�nXd
efd��YZdefd
��YZd�Zd�Zd�Zedkr-ejdd�ndS(i�N(tStringIO(tListType(t
TestEmailBase(tTestSkippedtrun_unittest(t__file__(t
_structurecCsMddlm}m}m}|||t�tjd|��}t|d�S(Ni�(tjointdirnametabspathtmoredatatr(tos.pathRRR ttestfiletostpardirtopen(tfilenameRRR tpath((s3/sys/lib/python2.7/email/test/test_email_torture.pytopenfiles$scrispin-torture.txttTortureBasecBseZd�ZRS(cCs1t|�}ztj|�}Wd|j�X|S(N(Rtemailtmessage_from_filetclose(tselfRtfptmsg((s3/sys/lib/python2.7/email/test/test_email_torture.pyt_msgobj$s
(t__name__t
__module__R(((s3/sys/lib/python2.7/email/test/test_email_torture.pyR#stTestCrispinTorturecBseZd�ZRS(cCs�|j}|j}|jd�}|j�}|t|�t�|t|�d�||jd�||j d�t
�}t|d|�||j�d�dS(Nscrispin-torture.txtis
Rs:multipart/mixed
text/plain
message/rfc822
multipart/alternative
text/plain
multipart/mixed
text/richtext
application/andrew-inset
message/rfc822
audio/basic
audio/basic
image/pbm
message/rfc822
multipart/mixed
multipart/mixed
text/plain
audio/x-sun
multipart/mixed
image/gif
image/gif
application/x-be2
application/atomicmail
audio/x-sun
message/rfc822
multipart/mixed
text/plain
image/pgm
text/plain
message/rfc822
multipart/mixed
text/plain
image/pbm
message/rfc822
application/postscript
image/gif
message/rfc822
multipart/mixed
audio/basic
audio/basic
message/rfc822
multipart/mixed
application/postscript
text/plain
message/rfc822
multipart/mixed
text/plain
multipart/parallel
image/gif
audio/basic
application/atomicmail
message/rfc822
audio/x-sun
(
tassertEqualtndiffAssertEqualRtget_payloadttypeRtlentpreambletNonetepilogueRRtgetvalue(RteqtneqRtpayloadR((s3/sys/lib/python2.7/email/test/test_email_torture.pyttest_mondo_message0s 5(RRR+(((s3/sys/lib/python2.7/email/test/test_email_torture.pyR.scCsBtjt}gt|�D]$}|jd�rt||�^qS(NtTest(tsystmodulesRtdirt
startswithtgetattr(tmodtname((s3/sys/lib/python2.7/email/test/test_email_torture.pyt_testclassesus
cCs:tj�}x't�D]}|jtj|��qW|S(N(tunittestt TestSuiteR4taddTestt makeSuite(tsuitet testclass((s3/sys/lib/python2.7/email/test/test_email_torture.pyR9zscCs"xt�D]}t|�q
WdS(N(R4R(R:((s3/sys/lib/python2.7/email/test/test_email_torture.pyt test_main�st__main__tdefaultTestR9(R-RR5t cStringIORttypesRtemail.test.test_emailRttest.test_supportRRRRR
temail.iteratorsRRtIOErrorRRR4R9R;Rtmain(((s3/sys/lib/python2.7/email/test/test_email_torture.pyt<module> s*
G
|