Uname: Linux web3.us.cloudlogin.co 5.10.226-xeon-hst #2 SMP Fri Sep 13 12:28:44 UTC 2024 x86_64
Software: Apache
PHP version: 8.1.31 [ PHP INFO ] PHP os: Linux
Server Ip: 162.210.96.117
Your Ip: 3.15.141.201
User: edustar (269686) | Group: tty (888)
Safe Mode: OFF
Disable Function:
NONE

name : test_sort.pyc
�
?��cc@s�ddlmZddlZddlZddlZejZdadd�Zdej	fd��YZ
dej	fd��YZd	ej	fd
��YZdd�Z
edkr�e
d
e�ndS(i����(ttest_supportNicCs�trdG|GHn|}|r/|j|�n
|j�t|�t|�kr�dG|GHdGt|�Gt|�GH|GH|GH|GHtd7adSxgt|�D]Y\}}||}||k	r�dG|GHdG|G|G|GH|GH|GH|GHtd7adSq�WdS(Ns    checkingserror inslength mismatch;isout of order at index(tverbosetsorttlentnerrorst	enumerate(ttagtexpectedtrawtcomparetorigtitgoodtmaybe((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pytcheck	s0
	

	
tTestBasecBseZd�ZRS(cs�dg}x?tdd�D].}d|}|jt|d|d��qW|jdddg�dtf�fd��Y�d	tfd
��Y}x|D]}t|�}tr�dG|GHn|}td||�|}|j�td
||�|}tj|�td||�|}|j�|}td||d��tr[dGHdGHn|}|jd��td||�g|D]}�|�^q�}|}tj|�t	�_
t}	y|j�Wntk
r�t	}	nX|	rt�_
td||�ngt
|�D]}|tjd�|�^q}g|D]}
|
|
jf^qF}|j�g|D]\}
}|
^qr}td||�q�WdS(Niii
iidi�t	Complainscs/eZeZd�Z�fd�Zd�ZRS(cSs
||_dS(N(R(tselfR((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyt__init__5scsJ�jr:tj�dkr:tr1dG|G|GHnt�n|j|jkS(Ng����MbP?s        complaining at(tmaybe_complaintrandomRtRuntimeErrorR(Rtother(R(s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyt__lt__8s
	cSsd|jS(Ns
Complains(%d)(R(R((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyt__repr__?s(t__name__t
__module__tTrueRRRR((R(s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyR2s	tStablecBs)eZd�Zd�ZdZd�ZRS(cSs||_||_dS(N(tkeytindex(RRR((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyRCs	cSst|j|j�S(N(tcmpR(RR((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyt__cmp__GscSsd|j|jfS(NsStable(%d, %d)(RR(R((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyRKsN(RRRR tNonet__hash__R(((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyRBs		sTesting sizetidentitytreversedsrandom permutationsreversed via functioncSs
t||�S(N(R(tatb((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyt<lambda>ats3    Checking against an insane comparison function.s?        If the implementation isn't careful, this may segfault.cSsttj�d�dS(Nii(tintR(R%R&((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyR'gR(s(an insane function left some permutations+exception during sort left some permutationt	stability(trangetextendtobjectRRtreverseRtshuffleRRRtFalseRtxranget	randrangeR(RtsizestpowertnRtxtstyRt
it_complainedtet	augmented((Rs5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyttestStressfully*s\	
"




	

	1"
(RRR<(((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyR)stTestBugscBs#eZd�Zd�Zd�ZRS(csRdd�fd��Y}gtd�D]}|�^q&�|jt�j�dS(NtCcseZ�fd�ZRS(csB�r%tj�dkr%�j�n
�jd�tj�dkS(Ng�?ig�?(Rtpoptappend(RR(tL(s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyR�s

(RRR((RA(s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyR>�si2((R+tassertRaisest
ValueErrorR(RR>R((RAs5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyttest_bug453523�s"cCs@td�}tj|�|jd�|j|td��dS(Ni2(R+RR/RR!tassertEqual(RRA((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyttest_cmpNone�s

cs�g}xstd�D]e}�fd�}ddg�|jt�j|��fd�}|jt�j|�|g}qWdS(Nics$�jd��j�t||�S(Ni(R@R?R(R6R8(RA(s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pytmutating_cmp�s

iics�jd��2t||�S(Ni(R@R(R6R8(RA(s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyRG�s
(R+RBRCR(RtmemorywasterRRG((RAs5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyttest_undetected_mutation�s(RRRDRFRI(((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyR=s		tTestDecorateSortUndecoratecBskeZd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Z	d�Z
d	�Zd
�ZRS(cCsJdj�}|}tj|�|jdtj�|jdd��dS(Ns,The quick Brown fox Jumped over The lazy DogRRcSst|j�|j��S(N(Rtlower(R6R8((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyR'�R((tsplitRR/RtstrRK(Rtdatatcopy((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyttest_decorated�s

cCs,dj�}|jt|jdd��dS(Ns,The quick Brown fox Jumped over The lazy DogcSsdS(Ni((R6R8((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyR'�R((RLRBt	TypeErrorRR!(RRN((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyttest_baddecorator�scCsfgtd�D]}tjd�|f^q
}|}|jdd��|j�|j||�dS(Ni�idRcSs|dS(Ni((R6((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyR'�R((R1RR2RRE(RRRNRO((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyttest_stability�s
.
cs8�fd�}dj�}|jd|dtj�dS(Ncs9�jt|�t��jt|�t�t||�S(N(REttypeRMR(R6R8(R(s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyR	�ss,The quick Brown fox Jumped over The lazy DogRR(RLRRMRK(RR	RN((Rs5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyttest_cmp_and_key_combination�scCs,dj�}|jt|jdtj�dS(Ns,The quick Brown fox Jumped over The lazy Dogtbad(RLRBRQRRMRK(RRN((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyttest_badcmp_with_key�scCsFtdd�}|}|jt|jdd��|j||�dS(Ni����icSsd|S(Ni((R6((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyR'�R((R+RBtZeroDivisionErrorRR!RE(RRNtdup((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyttest_key_with_exception�scs8td���fd�}|jt�jd|�dS(Ni
cs�2td��(|S(Ni(R+(R6(RN(s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pytk�s
R(R+RBRCR(RR[((RNs5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyttest_key_with_mutation�scsEtd��dtf�fd��Y}|jt�jd|�dS(Ni
t
SortKillercs eZd�Z�fd�ZRS(cSsdS(N((RR6((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyR�scs�2td��(dS(Ni(R+(R(RN(s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyt__del__�s(RRRR^((RN(s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyR]�s	R(R+R-RBRCR(RR]((RNs5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyttest_key_with_mutating_del�scsEtd��dtf�fd��Y}|jt�jd|�dS(Ni
R]cs eZd�Z�fd�ZRS(cSs|dkrt�ndS(Ni(R(RR6((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyR�scs�2td��(dS(Ni(R+(R(RN(s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyR^�s(RRRR^((RN(s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyR]�s	R(R+R-RBRR(RR]((RNs5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyt(test_key_with_mutating_del_and_exception�scCs_td�}tj|�|jdt�|j|tddd��|jt|jd�dS(NidR.ici����s
wrong type(R+RR/RRRERBRQ(RRN((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyttest_reverse�s

cCs�gtd�D]}tjd�|f^q
}|}|}|jdd�dt�|jdd��|j||�|jdd�dt�|j||�dS(	Ni�idRcSst|d|d�S(Ni(R(R6R8((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyR'R(R.cSst|d|d�S(Ni(R(R6R8((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyR'R(RcSs|dS(Ni((R6((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyR'	R((R1RR2RRRE(RRRNtcopy1tcopy2((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyttest_reverse_stabilitys.(
RRRPRRRSRURWRZR\R_R`RaRd(((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyRJ�s									
		cCs�tttf}tjdtf���tj|�|r�ttd�r�ddl	}dgd}xAtt|��D]-}tj|�|j
�tj�||<qsW|GHnWdQXdS(Ns!the cmp argument is not supportedtgettotalrefcounti����i(RRJR=Rtcheck_py3k_warningstDeprecationWarningtrun_unittestthasattrtsystgcR!R1RtcollectRe(Rttest_classesRktcountsR((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyt	test_mains	



t__main__R(ttestRRRjtunittestRRR!RtTestCaseRR=RJRoRR(((s5/usr/local/python-2.7/lib/python2.7/test/test_sort.pyt<module>s	 V-b
© 2025 GrazzMean