Current File : //opt/imh-python/lib/python2.7/test/test_marshal.pyc
�
��Wc@s�ddlmZddlZddlZddlZddlZyddlZWnek
ridZnXdej	fd��YZ
dej	fd��YZdej	fd��YZd	ej	fd
��YZ
dej	fd��YZd
ej	fd��YZdej	fd��YZdZejdkr4dndZejdkrOdndZejeejkd�dej	fd��Y�Zejejed�dej	fd��Y��Zd�Zedkr�e�ndS( i����(ttest_supportNtIntTestCasecBs#eZd�Zd�Zd�ZRS(cCs�tj}x�|r�x�||fD]{}tj|�}tj|�}|j||�tj|ttj	d��tj
ttj	d��}|j||�q W|d?}qWtjtj	�dS(Ntwbtrbi(
tsystmaxinttmarshaltdumpstloadstassertEqualtdumptfileRtTESTFNtloadtostunlink(tselftntexpectedtstgot((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyt	test_intss		cCs�d�}d
}|d}x~||||d?fD]d}x[|r�d||d�}tj|�}|j||�|dkr�d}q<|dL}q<Wq3WdS(NcSsKg}x5t|�D]'}|jt|d@��|dL}qWdj|�S(Ni�it(trangetappendtchrtjoin(tvaluetnbytestbytesti((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pytto_little_endian_string!s
li?itIii����ill����(RRR	(RRtmaxint64tminint64tbaseRR((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyt
test_int64s			cCs�x�ttfD]�}tjtj|��}|j||�|jt|�t|��tj|tt	j
d��tjtt	j
d��}|j||�|jt|�t|��q
WdS(NRR(tTruetFalseRRRR	ttypeR
RRRR
(Rtbtnew((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyt	test_bool5s(t__name__t
__module__RR$R*(((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyRs		t
FloatTestCasecBseZd�ZRS(cCs�d}tjd}x�||kr�x�||fD]�}t|�}tj|�}tj|�}|j||�tj|tt	j
d��tjtt	j
d��}|j||�q0W|d:}qWd}tj|d�}tj|�}|j||�tj|d�}tj|�}|j||�tjd	}x.||krnx||fD]}t|�}tj|�}tj|�}|j||�tj|d�}tj|�}|j||�tj|tt	j
d��tjtt	j
d��}|j||�tj|tt	j
d�d�tjtt	j
d��}|j||�q[W|d9}qAWtj
t	j
�dS(
Ng�}���:g�6�ҫ�sRRgS��:�^@giig��Z1%(RRtfloatRRRR	R
RRRR
RR(RtsmallRRtfRR((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyttest_floats@sJ

(R+R,R1(((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyR-?stStringTestCasecBs#eZd�Zd�Zd�ZRS(cCs�x�dddddgD]�}tjtj|��}|j||�|jt|�t|��tj|ttjd��tj	ttjd��}|j||�|jt|�t|��qWt
jtj�dS(Nuu
Andrè Previnuabcu i'RR(RRRR	R'R
RRRR
RR(RRR)((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyttest_unicodeps cCs�x�dddddgD]�}tjtj|��}|j||�|jt|�t|��tj|ttjd��tj	ttjd��}|j||�|jt|�t|��qWt
jtj�dS(NRsAndr� Previntabct i'RR(RRRR	R'R
RRRR
RR(RRR)((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyttest_string{s cCs�x�dddddgD]�}tjdtf��t|�}WdQXtjtj|��}|j||�tj|t	tj
d��tjt	tj
d��}|j||�qWtj
tj
�dS(	NRsAndr� PrevinR4R5i'sbuffer.. not supportedRR(Rtcheck_py3k_warningstDeprecationWarningtbufferRRRR	R
RRR
RR(RRR(R)((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyttest_buffer�s	
(R+R,R3R6R:(((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyR2os		tExceptionTestCasecBseZd�ZRS(cCs,tjtjt��}|jt|�dS(N(RRRt
StopIterationR	(RR)((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyttest_exceptions�s(R+R,R=(((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyR;�stCodeTestCasecBseZd�ZRS(cCs8tjj}tjtj|��}|j||�dS(N(R;R=t	func_codeRRRR	(RtcoR)((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyt	test_code�s(R+R,RA(((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyR>�stContainerTestCasecBsmeZidd6dd6dd6dd6d	gd
6dd6ed
6dd6Zd�Zd�Zd�Zd�ZRS(sfoo@bar.baz.spamtastringgH�zns�@tafloatiitanintlt
ashortlongs.zyx.41talisti
tatupletabooleanu
Andrè PrevintaunicodecCs�tjtj|j��}|j|j|�tj|jttjd��tj	ttjd��}|j|j|�t
jtj�dS(NRR(RRRtdR	R
RRRR
RR(RR)((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyt	test_dict�scCs�|jj�}tjtj|��}|j||�tj|ttj	d��tj
ttj	d��}|j||�tjtj	�dS(NRR(
RKtitemsRRRR	R
RRRR
RR(RtlstR)((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyt	test_list�scCs�t|jj��}tjtj|��}|j||�tj|tt	j
d��tjtt	j
d��}|j||�tj
t	j
�dS(NRR(ttupleRKtkeysRRRR	R
RRRR
RR(RttR)((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyt
test_tuple�scCs�x�ttfD]�}||jj��}tjtj|��}|j||�|jt	||��|j
t|�t|��tj|t
tjd��tjt
tjd��}|j||�tjtj�q
WdS(NRR(tsett	frozensetRKRQRRRR	t
assertTruet
isinstancetassertNotEqualtidR
RRRR
RR(RtconstructorRRR)((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyt	test_sets�si(s.zyx.41(
s.zyx.41s.zyx.41s.zyx.41s.zyx.41s.zyx.41s.zyx.41s.zyx.41s.zyx.41s.zyx.41s.zyx.41(R+R,R&RKRLRORSR[(((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyRB�s


					tBugsTestCasecBsYeZd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Z	d�Z
RS(	cCstjdgd�dS(Ni�i�(RR(R((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyttest_bug_5888452�scCsS|jttjd�|jttjd�|jttjtjd�d �dS(Nt0R0li����(tassertRaisest	ExceptionRRR(R((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyttest_patch_873224�scCsN|jtjtjdd��d�|jtjtjdd��d�dS(Niii(R	RRR(R((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyttest_version_argument�s%cCsYxRgtd�D]}t|�^qD]+}ytj|�Wq&tk
rPq&Xq&WdS(Ni(RRRRR`(RRtc((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyt	test_fuzz�s
,
cCs,dddd	}|jttj|�dS(
NRctXit{iitXXXXtXXXXXXXXXXXXXXXXi(R_t
ValueErrorRR(RR((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyttest_loads_recursion�scCs�g}}d}x2t|d�D] }|jdg�|d}q!Wtj|�}tj|�}|jt|�t|��|jt|d�t|d��|jt|d�t|d��|jdg�|jttj|�dS(Ni�iii����(	RRRRRR	tlenR_Ri(RtheadtlasttMAX_MARSHAL_STACK_DEPTHRtdatatnew_head((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyttest_recursion_limit�s
$$c	Cs^xWtttttttttf	D]4}t	d|fi�}|j
ttj
|��q"WdS(Ntsubtyp(tinttlongR.tcomplexRPtlisttdictRTRUR'R_RiRR(RttypRr((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyttest_exact_type_match�s(cCs'td�}d|}tj|�dS(Ng��.AR4(RsRR(Rtsizet
testString((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyttest_large_marshal
s
cCs d}|jttj|�dS(Ns	l(R_RiRR(Rtinvalid_string((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyttest_invalid_longss(R+R,R]RaRbRdRjRqRyR|R~(((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyR\�s								
	iii��iI����is!test cannot run on 32-bit systemstLargeValuesTestCasecBsPeZd�Zejdeddde�d��Zejdededde�d��Z	ejdede
de�d��Zejdede
de�d	��Zejdede
d
e
jed�de�d��Zejdede
d
e
jed�de�d��Zejdeddde�d
��ZRS(c	CsRttjd�}|jtjtj�|�|jttj||�WdQXdS(NR(	topenRRt
addCleanupRR_RiRR
(RRoR0((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pytcheck_unmarshallablesRztmemuseitdry_runcCs|jd|�dS(Ntx(R�(RRz((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyR6 sicCs|jd|�dS(Nux(R�(RRz((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyR3$scCs|jd|�dS(N(N(R�tNone(RRz((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyRS)scCs|jdg|�dS(N(R�R�(RRz((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyRO.sicCs|jtt|���dS(N(R�RTR(RRz((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyttest_set3scCs|jtt|���dS(N(R�RUR(RRz((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyttest_frozenset9scCs|jt|��dS(N(R�t	bytearray(RRz((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyttest_bytearray?s(R+R,R�Rtprecisionbigmemtestt
LARGE_SIZER&R6tcharacter_sizeR3tpointer_sizeRSRORt	getsizeofR�R�R�(((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyRs	'srequires _testcapit
CAPI_TestCasecBs>eZd�Zd�Zd�Zd�Zd�Zd�ZRS(cCsxxttjd�D]c}tjdtj|�ttjd��}|j�}WdQXtj	tj�|j
|d�qWdS(NiixV4RsxV4(RRtversiont	_testcapitpymarshal_write_long_to_fileRRR�treadRR	(RtvR0Ro((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyttest_write_long_to_fileHscCs�dddddddf}x�ttjd	�D]l}tj|tj|�ttjd
��}|j�}WdQXtj	tj�|j
tj|�|�q0WdS(Ns\u20acR4i{g������F@iy @s
long line i�iRy@ @(RRR�R�tpymarshal_write_object_to_fileRRR�R�RR	R(RtobjR�R0Ro((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyttest_write_object_to_filePscCstttjd��}|jd�WdQXtjtj�\}}tjtj�|j|d�|j|d�dS(NRs4xxxxi4i(R�RRtwriteR�tpymarshal_read_short_from_fileRR	(RR0trtp((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyttest_read_short_from_fileYscCstttjd��}|jd�WdQXtjtj�\}}tjtj�|j|d�|j|d�dS(NRsxV4xxxxixV4i(R�RRR�R�tpymarshal_read_long_from_fileRR	(RR0R�R�((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyttest_read_long_from_fileascCs�ddddd
f}x�ttjd�D]|}tj||�}ttjd��}|j|d	�WdQXtj	tj�\}}tj
tj�|j||�q)WdS(Ns\u20acR4i{g������F@iy @iRtxxxxy@ @(RRR�RR�RRR�R�t$pymarshal_read_last_object_from_fileRR	(RR�R�RoR0R�R�((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyttest_read_last_object_from_fileiscCs�ddddd
f}x�ttjd�D]�}tj||�}ttjd��}|j|d	�WdQXtj	tj�\}}tj
tj�|j||�|j|t|��q)WdS(Ns\u20acR4i{g������F@iy @iRR�y@ @(
RRR�RR�RRR�R�tpymarshal_read_object_from_fileRR	Rk(RR�R�RoR0R�R�((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyttest_read_object_from_filess(R+R,R�R�R�R�R�R�(((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyR�Ds						
c
Cs)tjtttttttt	t
�	dS(N(Rtrun_unittestRR-R2R>RBR;R\RR�(((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyt	test_mains	t__main__I�(ttestRRRtunittestRR�tImportErrorR�tTestCaseRR-R2R;R>RBR\R�t
maxunicodeR�tmaxsizeR�tskipIfRtcpython_onlyt
skipUnlessR�R�R+(((sj/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_marshal.pyt<module>s4

10#0G+9