Hacked By AnonymousFox

Current Path : /proc/thread-self/root/opt/alt/python27/lib64/python2.7/unittest/test/
Upload File :
Current File : //proc/thread-self/root/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyc

�
^
bc@sgddlZddlZdejfd��YZdejfd��YZedkrcej�ndS(i����NtTest_AssertionscBs,eZd�Zd�Zd�Zd�ZRS(cCsH|jdd�|jdd�|j|j|jdd�|j|j|jdd�|jdddd�|j|j|jdddd�|jdddd�|jdddd�|j|j|jdd
dd�|j|j|jdddd�|jtd
�td
��|j|j|jtd
�td
��dS(Ng�1��?g�?g����?g�������?tplacesiig�������?y�������?tinfy�������?�������?y�������?�������?y�������?�������?y�������?�������?(tassertAlmostEqualtassertNotAlmostEqualtassertRaisestfailureExceptiontfloat(tself((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttest_AlmostEquals$c	Cs�|jdddd�|jdddd�|jdddd�|jdddd�|jdddd�|j|j|jdddd�|j|j|jdddd�|j|j|jdddd�|jt|jdddddd�|jt|jdddddd�tjj�}|tjdd	�}|j||dtjdd
��|j||dtjdd��dS(Ng�������?g�?tdeltag�?g�������?Ritsecondsi
ii(RRRRt	TypeErrortdatetimetnowt	timedelta(Rtfirsttsecond((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttest_AmostEqualWithDeltas*c	Cs�d�}|jt|t�|jt|td��y|jtd��Wn)|jk
rw}|jd|j�nX|jd�y|jt|t�Wntk
r�nX|jd�|jt��*}y
t�Wntk
r�}�nXWdQX|j|j	|�|jt��td��WdQXy|jt��WdQXWn)|jk
rr}|jd|j�nX|jd�y |jt��t�WdQXWntk
r�nX|jd�dS(NcSs
|�dS(N((te((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyt_raise:stkeycSsdS(N(tNone(((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyt<lambda>?tsKeyError not raisedsassertRaises() didn't fails0assertRaises() didn't let exception pass through(
RtKeyErrorRtassertIntargstfailt
ValueErrort	ExceptiontassertIst	exception(RRRtcm((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttest_assertRaises9sB	







cCs|jdd�y|jddd�WnD|jk
rm}|jd|jd�|jd|jd�nX|jd�dS(NsAla ma kotasr+sk.ttMessages'kot'is*assertNotRegexpMatches should have failed.(tassertNotRegexpMatchesRRRR(RR((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttestAssertNotRegexpMatchesbs(t__name__t
__module__R	RR"R%(((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyRs			)tTestLongMessagecBs�eZdZd�Zd�Zd�Zd�Zd�Zd�Zd�Z	d�Z
d	�Zd
�Zd�Z
d�Zd
�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�ZRS(s�Test that the individual asserts honour longMessage.
    This actually tests all the message behaviour for
    asserts that use longMessage.cs`dtjf�fd��Y}dtjf�fd��Y}|d��_|d��_dS(NtTestableTestFalsecs eZeZ�jZd�ZRS(cSsdS(N((R((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttestTestws(R&R'tFalsetlongMessageRR*((R(sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyR)ss	tTestableTestTruecs eZeZ�jZd�ZRS(cSsdS(N((R((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyR*~s(R&R'tTrueR,RR*((R(sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyR-zs	R*(tunittesttTestCasettestableTruet
testableFalse(RR)R-((RsB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pytsetUprscCs|jtjj�dS(N(tassertFalseR/R0R,(R((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttestDefault�scCs�|j|jjdd�d�|j|jjdd�d�|j|jjdd�d�|j|jjdd�d�|jjt�d�dS(Ntfootbars	bar : foo(tassertEqualR2t_formatMessageRR1tobject(R((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttest_formatMsg�s
cCs6djd�td�D��}|jj|d�dS(NRcss|]}t|�VqdS(N(tchr(t.0ti((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pys	<genexpr>�si�u�(tjointrangeR1R9(Rtone((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyt test_formatMessage_unicode_error�sc
s���fd�}xxt|�D]j\}}||�}i}|d}	|	r]idd6}n�j�jd|��|||�WdQXqWdS(Ncs4|dk}|r�j}n	�j}t|��S(Ni(R2R1tgetattr(R>tuseTestableFalsettest(t
methodNameR(sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyt	getMethod�s
	itoopstmsgtexpected_regexp(t	enumeratetassertRaisesRegexpR(
RRFRterrorsRGR>RJt
testMethodtkwargstwithMsg((RFRsB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pytassertMessages�s

cCs&|jdtfddddg�dS(Nt
assertTrues^False is not true$s^oops$s^False is not true : oops$(RQR+(R((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttestAssertTrue�s	cCs&|jdtfddddg�dS(NR4s^True is not false$s^oops$s^True is not false : oops$(RQR.(R((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttestAssertFalse�s	cCs#|jddddddg�dS(NtassertNotEqualis^1 == 1$s^oops$s^1 == 1 : oops$(ii(RQ(R((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttestNotEqual�s	cCs#|jddddddg�dS(NRiis^1 != 2 within 7 places$s^oops$s^1 != 2 within 7 places : oops$(ii(RQ(R((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttestAlmostEqual�scCs#|jddddddg�dS(NRis^1 == 1 within 7 places$s^oops$s^1 == 1 within 7 places : oops$(ii(RQ(R((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttestNotAlmostEqual�scCs#|jddddddg�dS(Nt_baseAssertEqualiis^1 != 2$s^oops$s^1 != 2 : oops$(ii(RQ(R((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttest_baseAssertEqual�scCs,|jdgdgfddddg�dS(NtassertSequenceEquals\+ \[None\]$s^oops$s\+ \[None\] : oops$(RQR(R((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttestAssertSequenceEqual�s	cCs5|jdt�tdg�fddddg�dS(NtassertSetEqualsNone$s^oops$sNone : oops$(RQtsetR(R((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttestAssertSetEqual�s	cCs)|jddgfddddg�dS(NRs^None not found in \[\]$s^oops$s^None not found in \[\] : oops$(RQR(R((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttestAssertIn�scCs,|jdddgfddddg�dS(NtassertNotIns%^None unexpectedly found in \[None\]$s^oops$s,^None unexpectedly found in \[None\] : oops$(RQR(R((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttestAssertNotIn�scCs0|jdiidd6fddddg�dS(NtassertDictEqualtvalueRs\+ \{'key': 'value'\}$s^oops$s\+ \{'key': 'value'\} : oops$(RQ(R((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttestAssertDictEqual�scCs0|jdidd6ifddddg�dS(NtassertDictContainsSubsetRdRs^Missing: 'key'$s^oops$s^Missing: 'key' : oops$(RQ(R((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttestAssertDictContainsSubset�scCs#|jddddddg�dS(NtassertMultiLineEqualRR6s\+ foo$s^oops$s\+ foo : oops$(RR6(RQ(R((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttestAssertMultiLineEqual�scCs#|jddddddg�dS(Nt
assertLessiis^2 not less than 1$s^oops$s^2 not less than 1 : oops$(ii(RQ(R((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttestAssertLess�scCs#|jddddddg�dS(NtassertLessEqualiis^2 not less than or equal to 1$s^oops$s&^2 not less than or equal to 1 : oops$(ii(RQ(R((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttestAssertLessEqual�scCs#|jddddddg�dS(Nt
assertGreateriis^1 not greater than 2$s^oops$s^1 not greater than 2 : oops$(ii(RQ(R((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttestAssertGreater�scCs#|jddddddg�dS(NtassertGreaterEqualiis"^1 not greater than or equal to 2$s^oops$s)^1 not greater than or equal to 2 : oops$(ii(RQ(R((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttestAssertGreaterEqualscCs#|jddddddg�dS(NtassertIsNonesnot Nones^'not None' is not None$s^oops$s^'not None' is not None : oops$(snot None(RQ(R((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttestAssertIsNonescCs#|jddddddg�dS(NtassertIsNotNones^unexpectedly None$s^oops$s^unexpectedly None : oops$(N(RQR(R((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttestAssertIsNotNonescCs#|jddddddg�dS(NRR6s^None is not 'foo'$s^oops$s^None is not 'foo' : oops$(NR6(RQR(R((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttestAssertIsscCs#|jddddddg�dS(NtassertIsNots^unexpectedly identical: None$s^oops$s%^unexpectedly identical: None : oops$(NN(RQR(R((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyttestAssertIsNots(R&R't__doc__R3R5R;RBRQRSRTRVRWRXRZR\R_R`RbReRgRiRkRmRoRqRsRuRvRx(((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyR(ms6			
																						t__main__(R
R/R0RR(R&tmain(((sB/opt/alt/python27/lib64/python2.7/unittest/test/test_assertions.pyt<module>s
g�

Hacked By AnonymousFox1.0, Coded By AnonymousFox