Current File : //opt/imh-python/lib/python2.7/test/test_source_encoding.pyc
�
��Wc@s�ddlZddlmZmZmZddlZddlZddlZdejfd��YZ	dd
d��YZ
de
ejfd��YZd	e
ejfd
��YZd�Z
edkr�e
�ndS(i����N(trun_unittesttrmtreetcaptured_stdouttMiscSourceEncodingTestcBsbeZd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Z	d�Z
d	�ZRS(
cCs6|jdjd�d�|jdjd�d�dS(Nu
Питонsutf-8s
Питонu\Пs\П(tassertEqualtencode(tself((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyttest_pep263scBs8eddd�}i}||U|j|dd�dS(Ns
# coding: utf-8
u = u'ó'
tdummytexectuuó(tcompileR(Rtctd((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyttest_compilestringscBs`eddd�}i}||U|j|d|d�|je|d�e|d��dS(Ns!a, b = '\U0001010F', '\U0001010F'RR	tatb(RRtlen(RRR
((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyttest_issue3297s
cCs*|jttd�|jttd�dS(Ns� s� (tassertRaisestSyntaxErrorteval(R((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyttest_issue7820#scCstddd�tddd�tddd�|jtd��tddd�WdQX|jtd��td	dd�WdQX|jtd
��td	dd�WdQX|jtd��tddd�WdQX|jtd
��tddd�WdQXdS(Ns# -*- coding: iso-8859-15 -*-
RR	s
s# -*- coding: utf-8 -*-
tfakes# -*- coding: fake -*-
siso-8859-15s!# -*- coding: iso-8859-15 -*-
tBOMs# -*- coding: fake -*-
(RtassertRaisesRegexpR(R((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyttest_error_message.scCs-|jtd��ddlm}WdQXdS(Nscodec did not return a unicodei����(tbad_coding3(RRttestR(RR((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyttest_non_unicode_codec?s	
cCsd}|j|�dS(Nt
bad_coding(tverify_bad_module(Rtmodule_name((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyttest_bad_codingEscCsd}|j|�dS(Ntbad_coding2(R(RR ((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyttest_bad_coding2IscCs�|jttd|�tjjt�}tjj||d�}t|��}|j	�}WdQX|jtt
||d�dS(Nstest.s.pyR	(RRt
__import__tostpathtdirnamet__file__tjointopentreadR(RR R&tfilenametfpttext((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyRMscCsadjd�}|jt��}t|dd�WdQXd}|j|jjdj|��dS(Nu# coding: ascii
☃sutf-8s<string>R	sN'ascii' codec can't decode byte 0xe2 in position 16: ordinal not in range(128)i(RRRRt
assertTruet	exceptiontargst
startswith(RtinputRtexpected((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyttest_error_from_stringVs
(t__name__t
__module__RRRRRRR!R#RR5(((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyR	s	
									tAbstractSourceEncodingTestcBsPeZd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Z	RS(cCsd}|j|d�dS(Ns&#coding:iso8859-15
print(repr(u"ä"))
s
u'\xc3\u20ac'(tcheck_script_output(Rtsrc((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyttest_first_coding_linebscCsd}|j|d�dS(Ns(#
#coding:iso8859-15
print(repr(u"ä"))
s
u'\xc3\u20ac'(R9(RR:((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyttest_second_coding_linegscCsd}|j|d�dS(Ns5#coding:iso8859-15
#coding:latin1
print(repr(u"ä"))
s
u'\xc3\u20ac'(R9(RR:((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyttest_double_coding_linemscCsd}|j|d�dS(Ns4#coding:iso8859-15 coding:latin1
print(repr(u"ä"))
s
u'\xc3\u20ac'(R9(RR:((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyttest_double_coding_same_linetscCsd}|j|d�dS(Ns)#coding:iso-8859-15 �
print(repr(u"ä"))
s
u'\xc3\u20ac'(R9(RR:((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyttest_first_non_utf8_coding_lineyscCsd}|j|d�dS(Ns*
#coding:iso-8859-15 �
print(repr(u"ä"))
s
u'\xc3\u20ac'(R9(RR:((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyt test_second_non_utf8_coding_line~scCsd}|j|d�dS(Nsprint(repr(u"ä"))
su'\xe4'(R9(RR:((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyt
test_utf8_bom�scCsd}|j|d�dS(Ns$#coding:utf-8
print(repr(u"ä"))
su'\xe4'(R9(RR:((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyt"test_utf8_bom_and_utf8_coding_line�s(
R6R7R;R<R=R>R?R@RARB(((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyR8`s							tBytesSourceEncodingTestcBseZd�ZRS(cBsIe��}|dUWdQX|j�jd�}|j|j�|�dS(Ntlatin1(RtgetvalueRRtrstrip(RR:R4tstdouttout((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyR9�s(R6R7R9(((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyRC�stFileSourceEncodingTestcBseZd�ZRS(c	Cs�tj�}zVtjj|d�}t|d��}|j|�WdQXtj|�\}}}Wdt	|�X|j
|j�|�dS(Nstest.pytwb(ttempfiletmkdtempR%R&R)R*twritet
script_helpertassert_python_okRRRF(	RR:R4ttmpdtfnR-trcRHterr((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyR9�s(R6R7R9(((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyRI�scCstttt�dS(N(RRRCRI(((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyt	test_main�st__main__((tunittestttest.test_supportRRRRNR%RKtTestCaseRR8RCRIRTR6(((sr/builddir/build/BUILDROOT/imh-python-2.7.12-1.el7.x86_64/opt/imh-python/lib/python2.7/test/test_source_encoding.pyt<module>sW.