%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /usr/local/lib/python2.7/test/
Upload File :
Create Path :
Current File : //usr/local/lib/python2.7/test/test_shutil.pyo

ó
Nêáac@sddlZddlZddlZddlZddlZddlZddlZddlZddlZddl	m
Z
ddlmZmZm
Z
mZddlZddlZddlmZddlmZmZmZedZy"ddlZddlZeZWnek
r'eZnXyddlZWnek
rQe ZnXy"ddl!Z!ddlZeZ"Wnek
r“e
dƒZ"nXdej#fd	„ƒYZ$d
ej#fd„ƒYZ%dej#fd
„ƒYZ&d„Z'e(dkrþe'ƒndS(iÿÿÿÿN(tfind_executable(tmake_archivetregister_archive_formattunregister_archive_formattget_archive_formats(ttest_support(tTESTFNtcheck_warningstcaptured_stdoutt2tzipt
TestShutilcBsåeZd„Zd„Zdd„Zd„Zd„Zeje	e
dƒdƒejej
d d	kd
ƒeje	e
dƒoŽe
jƒdkd
ƒd„ƒƒƒZd„Zd„Zd„Zd„Ze	e
dƒrîd„Zd„Zneje	e
dƒdƒd„ƒZeje	e
dƒdƒd„ƒZeje	e
dƒofe	edƒofe	edƒdƒd„ƒZejedƒd „ƒZd!„Zd"d#„Zejed$ƒejed%ƒd&ƒd'„ƒƒZeje d(ƒd)„ƒZ!eje d(ƒejed*ƒd+ƒd,„ƒƒZ"eje d(ƒejed-ƒd.ƒd/„ƒƒZ#d0„Z$ejed$ƒd1„ƒZ%ejed$ƒeje&d2ƒd3„ƒƒZ'd4„Z(d5„Z)ejed$ƒd6„ƒZ*d7„Z+RS(8cCs tt|ƒjƒg|_dS(N(tsuperRtsetUpttempdirs(tself((s,/usr/local/lib/python2.7/test/test_shutil.pyR
-scCsOtt|ƒjƒx5|jrJ|jjƒ}tj|tjdkƒqWdS(Ntnttcygwin(RR(	RRttearDownRtpoptshutiltrmtreetostname(Rtd((s,/usr/local/lib/python2.7/test/test_shutil.pyR1stxxxcCs\t|ttfƒr*tjj|Œ}nt|dƒ}z|j|ƒWd|jƒXdS(sWWrites a file in the given path.


        path can be a string or a sequence.
        twN(	t
isinstancetlistttupleRtpathtjointopentwritetclose(RRtcontenttf((s,/usr/local/lib/python2.7/test/test_shutil.pyt
write_file7scCs tjƒ}|jj|ƒ|S(sjCreate a temporary directory that will be cleaned up.

        Returns the path of the directory.
        (ttempfiletmkdtempRtappend(RR((s,/usr/local/lib/python2.7/test/test_shutil.pyR'EscCs&tjƒ}|jttj|ƒdS(N(R&tmktemptassertRaisestOSErrorRR(Rtfilename((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_rmtree_errorsMstchmodsrequires os.chmod()iRs2This test can't be run on Cygwin (issue #1071513).tgeteuidis9This test can't be run reliably as root (issue #1076467).cCsúd|_tjtƒtjjtdƒ|_t|jdƒ}|jƒtj	tƒj
}tj	|jƒj
}tj|jt	jƒtjtt	jƒt
jtd|jƒ|j|jddƒtjt|ƒtj|j|ƒt
jtƒdS(NitaRtonerroris1Expected call to onerror function did not happen.(t
errorStateRtmkdirRRRt	childpathR R"tstattst_modeR.tS_IREADRRtcheck_args_to_onerrortassertEqual(RR$told_dir_modetold_child_mode((s,/usr/local/lib/python2.7/test/test_shutil.pyt
test_on_errorRs	

cCsÊ|jdkr€|tjkr4|j||jƒn&|j|tjdƒ|j|tƒ|jt	|dt
ƒƒd|_nF|j|tjƒ|j|tƒ|jt	|dt
ƒƒd|_dS(Nis+func must be either os.remove or os.listdirii(R2RtremoveR9R4tassertIstlistdirRt
assertTruet
issubclassR+trmdir(Rtfunctargtexc((s,/usr/local/lib/python2.7/test/test_shutil.pyR8oscCsLtjƒ\}}tj|ƒjƒ|jttj|ƒtj	|ƒdS(N(
R&tmkstempRtfdopenR"R*R+RRR=(RthandleR((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_rmtree_dont_delete_file‰sc
CsFd„}d„}tjƒ}tjjtjƒdƒ}|tjj|dƒdƒtjtjj|dƒƒ|tjj|ddƒdƒzètj||ƒ|jtjj	tjj|dƒƒƒ|jtjj
tjj|dƒƒƒ|jtjj	tjj|ddƒƒƒ|tjj|dƒƒ}|j|dƒ|tjj|ddƒƒ}|j|dƒWdx~tjj|dƒtjj|dƒtjj|ddƒtjj|ddƒfD](}tjj|ƒrÐtj
|ƒqÐqÐWxB|tjj|ƒfD](}tjj|ƒrtj|ƒqqWXdS(NcSs*t|dƒ}|j|ƒ|jƒdS(NR(R R!R"(RtdataR$((s,/usr/local/lib/python2.7/test/test_shutil.pyt
write_data‘s
cSs&t|ƒ}|jƒ}|jƒ|S(N(R treadR"(RR$RJ((s,/usr/local/lib/python2.7/test/test_shutil.pyt	read_data–s
tdestinationstest.txtt123ttest_dirt456(R&R'RRRR3RtcopytreeR@tisfiletisdirR9texistsR=tdirnameR(RRKRMtsrc_dirtdst_dirtactualR((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_copytree_simples8		((
c	CsTd„}d„}tjj}tjj}tjƒ}zð|tjƒdƒ}|||dƒdƒ|||dƒdƒtj||dƒƒ|||ddƒdƒtj||d	ƒƒ|||d	dƒdƒtj||d	d
ƒƒtj||d	dƒƒ|||d	d
dƒdƒ|||d	ddƒdƒz‚tjd
d	ƒ}tj	||d|ƒ|j
|||dƒƒƒ|j
|||dƒƒƒ|j
|||d	ƒƒƒWdtjj|ƒrétj|ƒnXz‰tjd
dƒ}tj	||d|ƒ|j
|||dƒƒƒ|j
|||d	dƒƒƒ|j
|||d	d
ƒƒƒWdtjj|ƒr˜tj|ƒnXzfd„}tj	||d|ƒ|j
|||d	ddƒƒƒ|j
|||d	d
ƒƒƒWdtjj|ƒr$tj|ƒnXWdtj|ƒtjtjj|ƒƒXdS(NcSs*t|dƒ}|j|ƒ|jƒdS(NR(R R!R"(RRJR$((s,/usr/local/lib/python2.7/test/test_shutil.pyRK¿s
cSs&t|ƒ}|jƒ}|jƒ|S(N(R RLR"(RR$RJ((s,/usr/local/lib/python2.7/test/test_shutil.pyRMÄs
RNstest.txtROstest.tmpRPRQt	test_dir2tsubdirtsubdir2stest.pys*.tmptignoressubdir*cSs”g}x‡|D]}tjj||ƒ}tjj|ƒr`|jƒddkr`|j|ƒq
tjj|ƒddkr
|j|ƒq
q
W|S(NiÿÿÿÿR\s.py(RRRRTtsplitR(tsplitext(tsrctnamestresRR((s,/usr/local/lib/python2.7/test/test_shutil.pyt_filterôs
(
RRRRUR&R'R3Rtignore_patternsRRR@RRV(	RRKRMRRURWRXtpatternsRd((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_copytree_with_exclude½sV		! $	$
tsymlinkcCs\tjtƒtjjtdƒ}tjjtdƒ}zøt|dƒ}|jdƒ|jƒtj||ƒ|j	t
jt
j||ƒt|dƒ}|j
|jƒdƒWdQXtj|ƒtjd|ƒ|j	t
jt
j||ƒt|dƒ}|j
|jƒdƒWdQXtj|ƒWdyt
jtƒWntk
rVnXXdS(NtcheesetshopRtcheddartr(RR3RRRR R!R"tlinkR*RtErrortcopyfileR9RLR=RhRR+(RRatdstR$((s,/usr/local/lib/python2.7/test/test_shutil.pyt'test_dont_copy_file_onto_link_to_itselfs*




cCs‰tjtƒzatjjtdƒ}tjjtdƒ}tj|ƒtj||ƒ|jttj	|ƒWdtj	tdt
ƒXdS(NRiRjt
ignore_errors(RR3RRRRhR*R+RRtTrue(RRaRp((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_rmtree_on_symlink-s

tmkfifosrequires os.mkfifo()cCs^tjtƒz<|jtjtjttƒ|jtjtjttƒWdtj	tƒXdS(N(
RRuRR*RtSpecialFileErrorRotTESTFN2t__file__R=(R((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_copyfile_named_pipe:s
cCstjtƒzÌtjjtdƒ}tj|ƒtjj|dƒ}tj|ƒytjttƒWn`tj	k
rÊ}|j
d}|jt|ƒdƒ|d\}}}|jd||ƒnX|j
dƒWdtjtdtƒtjtdtƒXdS(NR\tmypipeiis`%s` is a named pipes$shutil.Error should have been raisedRr(RR3RRRRuRRRRwRntargsR9tlentfailRRs(RR\tpipeteterrorsRaRpt	error_msg((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_copytree_named_pipeEs 



tchflagst
EOPNOTSUPPtENOTSUPs)requires os.chflags, EOPNOTSUPP & ENOTSUPcCsë|jƒ}tjj|dƒ}tjj|dƒ}|j|dƒ|j|dƒd„}tj}zrx9tjtjfD]%}||ƒt_t	j
||ƒq~W|tjtjƒt_|jtt	j
||ƒWd|t_XdS(Ntfile1tfile2Rcstƒ‰‡‡fd†}|S(Ncsˆˆ_ˆ‚dS(N(terrno(Rtflags(terrtex(s,/usr/local/lib/python2.7/test/test_shutil.pyt_chflags_raiserhs	(R+(RŠRŒ((RŠR‹s,/usr/local/lib/python2.7/test/test_shutil.pytmake_chflags_raiseres	(
R'RRRR%RƒRˆR„R…RtcopystatR*R+(RttmpdirR†R‡Rtold_chflagsRŠ((s,/usr/local/lib/python2.7/test/test_shutil.pyt-test_copystat_handles_harmless_chflags_errorsZs		s
requires zlibc	Cså|jdƒ\}}|jƒ}tj|ƒtjj|ƒ}tjjtjj|ƒdƒ}tj	|ƒ,tjj
|ƒ}t|d|dƒ}WdQX|j||dƒ|j
tjj|ƒƒ|j
tj|ƒƒtj|dƒ5}|jt|jƒƒdddd	d
dgƒWdQXtj	|ƒt|d|dƒ}WdQX|j||d
ƒ|j
tjj|ƒƒ|j
tj|ƒƒtj|dƒ5}|jt|jƒƒdddd	d
dgƒWdQXdS(Nttarchivetgztart.s.tar.gzsr:gzs./file1s./file2s./subs./sub/file3s./sub2ttars.tarRl(t
_create_filesR'RRBRRVRtbasenametsupportt
change_cwdtabspathRR9R@RSttarfilet
is_tarfileR tsortedtgetnames(	Rtroot_dirtbase_dirttmpdir2twork_dirt
rel_base_namet	base_namettarballttf((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_make_tarballws0
!		cCs<tj|ƒ'}|jƒ}|jƒt|ƒSWdQXdS(N(RœR RŸtsortR(RRR–Rb((s,/usr/local/lib/python2.7/test/test_shutil.pyt_tarinfo›s
tdistcCsé|jƒ}tjj||ƒ}tjj|ƒsCtj|ƒn|j|dfdƒ|j|dfdƒtjtjj|dƒƒ|j|ddfdƒtjtjj|dƒƒ|rß|j|dfdƒn||fS(NR†RR‡tsubtfile3tsub2touter(R'RRRRTtmakedirsR%R3(RR¡R R«((s,/usr/local/lib/python2.7/test/test_shutil.pyR—¡ss
Requires zlibR–sNeed the tar command to runcCsr|jƒ\}}tjj|jƒdƒ}t|d||ƒ}|j||dƒ|jtjj|ƒƒtjj|dƒ}ddd|g}t	j
|d|ƒ|jtjj|ƒƒ|j|j|ƒ|j|ƒƒt|d||ƒ}|j||dƒ|jtjj|ƒƒt|d||d	tƒ}|j||dƒ|jtjj|ƒƒdS(
NR“R”s.tar.gzsarchive2.tarR–s-cftcwds.tartdry_run(
R—RRRR'RR9R@RSt
subprocesst
check_callRªRs(RR R¡R¥R¦ttarball2ttar_cmd((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_tarfile_vs_tar°s""	sNeed zip support to runc	Csû|jƒ\}}|jƒ}tj|ƒtjj|ƒ}tjjtjj|ƒdƒ}tj	|ƒ)tjj
|ƒ}t|d|ƒ}WdQX|j||dƒ|j
tjj|ƒƒ|j
tj|ƒƒtj|ƒ8}|jt|jƒƒdddddd	d
gƒWdQXtj|ƒtj	|ƒ,tjj
|ƒ}t|d||ƒ}WdQX|j||dƒ|j
tjj|ƒƒ|j
tj|ƒƒtj|ƒ5}|jt|jƒƒdddddd	gƒWdQXdS(NR“R
s.zipsdist/s
dist/file1s
dist/file2s	dist/sub/sdist/sub/file3s
dist/sub2/R¯(R—R'RRBRRVRR˜R™RšR›RR9R@RStzipfilet
is_zipfiletZipFileRžtnamelisttunlink(	RR R¡R¢R£R¤R¥Rctzf((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_make_zipfileÐs6
!		
	R
sNeed the zip command to runc
Cs-|jƒ\}}tjj|jƒdƒ}t|d||ƒ}|j||dƒ|jtjj|ƒƒtjj|dƒ}dddd|g}t	j
|d|ƒ|jtjj|ƒƒtj|ƒ}|j
ƒ}WdQXtj|ƒ}|j
ƒ}	WdQX|jt|ƒt|	ƒƒdS(NR“R
s.zipsarchive2.zips-qs-rR±(R—RRRR'RR9R@RSR³R´R¸RºR»Rž(
RR R¡R¥R“tarchive2tzip_cmdR½Rbtnames2((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_zipfile_vs_zipöstunzipsNeed the unzip command to runc		Cs|jƒ\}}tjj|jƒdƒ}t|d||ƒ}|j||dƒ|jtjj|ƒƒdd|g}t	j
|ƒ|ytj|dtj
ƒWnZtjk
r}|j}d|krâ|jdƒnd	}|j|j||ƒƒnXWdQXdS(
NR“R
s.zipRÃs-ttstderrsunrecognized option: tsunzip doesn't support -ts{}

**Unzip Output**
{}(R—RRRR'RR9R@RSR™RšR³tcheck_outputtSTDOUTtCalledProcessErrortoutputtskipTestR}tformat(	RR R¡R¥R“RÀREtdetailstmsg((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_unzip_zipfiles	cCs;|jƒ}tjj|dƒ}|jtt|dƒdS(NR“R(R'RRRR*t
ValueErrorR(RRR¥((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_make_archive'sc	CsFtr/tjdƒd}tjdƒd}n
d}}|jƒ\}}tjj|j	ƒdƒ}t
|d||d|d|ƒ}|jtjj|ƒƒt
|d||ƒ}|jtjj|ƒƒt
|d||d|d|ƒ}|jtjj|ƒƒt
|d||dddd	ƒ}|jtjj|ƒƒdS(
NitrootR“R
townertgroupR–t	kjhkjhkjgtoihohoh(
tUID_GID_SUPPORTtgrptgetgrgidtpwdtgetpwuidR—RRRR'RR@RS(RRÒRÑR R¡R¥Rc((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_make_archive_owner_group,s"
	sRequires grp and pwd supportc	
Cs|jƒ\}}tjj|jƒdƒ}tjdƒd}tjdƒd}t	j
|ƒ&t|d|dd|d|ƒ}WdQX|jtjj
|ƒƒtj|ƒ}zAx:|jƒD],}|j|jdƒ|j|jdƒqÂWWd|jƒXdS(NR“iR”R«RÑRÒ(R—RRRR'RÖR×RØRÙR™RšRR@RSRœR t
getmembersR9tuidtgidR"(	RR R¡R¥RÒRÑtarchive_nameR“tmember((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_tarfile_root_ownerGscCs…tjƒ}d„}td|gdƒzKytddd|jƒƒWntk
r[nX|jtjƒ|ƒWdtdƒXdS(Nc_s
tƒ‚dS(N(tRuntimeError(R{tkw((s,/usr/local/lib/python2.7/test/test_shutil.pyt_breaks`sRsxxx fileR (RtgetcwdRRR't	ExceptionR9R(Rtcurrent_dirRã((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_make_archive_cwd^s	
cCsp|jƒ}tjƒ}zCtj|ƒ|jtddƒdƒ|jtjjdƒƒWdtj|ƒXdS(NttestR–stest.tar(	R'RRätchdirR9RR@RRS(RR t	saved_dir((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_make_tarfile_in_curdirms
cCsp|jƒ}tjƒ}zCtj|ƒ|jtddƒdƒ|jtjjdƒƒWdtj|ƒXdS(NRèR
stest.zip(	R'RRäRéR9RR@RRS(RR Rê((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_make_zipfile_in_curdirxs
c	Csß|jttddƒ|jttdd„dƒ|jttdd„d	d
gƒtdd„dgdƒgtƒD]\}}|^qw}|jd|ƒtdƒgtƒD]\}}|^q³}|jd|ƒdS(NRicSstS(N(tx(((s,/usr/local/lib/python2.7/test/test_shutil.pyt<lambda>‡R’cSstS(N(Rí(((s,/usr/local/lib/python2.7/test/test_shutil.pyRî‰R’iicSstS(N(Rí(((s,/usr/local/lib/python2.7/test/test_shutil.pyRîŒR’sxxx file(ii(iii(ii(R*t	TypeErrorRRtassertInRtassertNotIn(RRtparamstformats((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_register_archive_format„s
"
"(,t__name__t
__module__R
RR%R'R-tunittestt
skipUnlessthasattrRtskipIftsystplatformR/R<R8RIRZRgRqRtRyR‚RˆR‘tzlibR¨RªR—RR·tZIP_SUPPORTR¾RÂRÍRÏRÚRÕRàRçRëRìRô(((s,/usr/local/lib/python2.7/test/test_shutil.pyR+sX				$			-	Q	
$$$	&			tTestMovecBsÂeZd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Z	d„Z
d	„Zd
„Zd„Z
d„Zejejjd
ƒd„ƒZd„Zd„Zd„Zd„ZRS(cCsãd}tjƒ|_tjƒ|_tjj|j|ƒ|_tjj|j|ƒ|_y@tjdtjj	t
ƒƒ|_tjj|j|ƒ|_Wnt
k
r¶d|_nXt|jdƒ}|jdƒWdQXdS(Ntfootdirtwbtspam(R&R'RWRXRRRtsrc_filetdst_fileRVRxtdir_other_fst
file_other_fsR+tNoneR R!(RR,R$((s,/usr/local/lib/python2.7/test/test_shutil.pyR
—s	

cCsKxD|j|j|jfD]*}y|r8tj|ƒnWqqXqWdS(N(RWRXRRR(RR((s,/usr/local/lib/python2.7/test/test_shutil.pyR©scCst|dƒ}|jƒ}WdQXtj||ƒt|dƒ}|j||jƒƒWdQX|jtjj|ƒƒdS(Ntrb(	R RLRtmoveR9tassertFalseRRRU(RRaRptreal_dstR$tcontents((s,/usr/local/lib/python2.7/test/test_shutil.pyt_check_move_file±scCsattj|ƒƒ}tj||ƒ|j|ttj|ƒƒƒ|jtjj|ƒƒdS(N(	RžRR?RR
R9RRRU(RRaRpRR
((s,/usr/local/lib/python2.7/test/test_shutil.pyt_check_move_dir¹scCs |j|j|j|jƒdS(N(RRR(R((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_move_file¿scCs |j|j|j|jƒdS(N(RRRXR(R((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_move_file_to_dirÃscCs9|js|jdƒn|j|j|j|jƒdS(Ns%dir on other filesystem not available(RRÉRRR(R((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_move_file_other_fsÇs	cCs9|js|jdƒn|j|j|j|jƒdS(Ns%dir on other filesystem not available(RRÉRRR(R((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_move_file_to_dir_other_fsÎs	cCsItjƒ}z|j|j||ƒWdytj|ƒWnnXXdS(N(R&R)RRWRR(RRX((s,/usr/local/lib/python2.7/test/test_shutil.pyt
test_move_dirÕscCsk|js|jdƒntjd|jƒ}z|j|j||ƒWdytj|ƒWnnXXdS(Ns%dir on other filesystem not availableR(RRÉR&R)RRWRR(RRX((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_move_dir_other_fsàs	cCs>|j|j|jtjj|jtjj|jƒƒƒdS(N(RRWRXRRRR˜(R((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_move_dir_to_diríscCsW|js|jdƒn|j|j|jtjj|jtjj|jƒƒƒdS(Ns%dir on other filesystem not available(RRÉRRWRRRR˜(R((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_move_dir_to_dir_other_fsòs	cCsH|j|jtjj|jtjj|jtjj|jƒƒƒdS(N(RRWRRtsepRXRR˜(R((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_move_dir_sep_to_dirùssrequires os.path.altsepcCsH|j|jtjj|jtjj|jtjj|jƒƒƒdS(N(RRWRRtaltsepRXRR˜(R((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_move_dir_altsep_to_dirýscCs?t|jdƒWdQX|jtjtj|j|jƒdS(NR(R RR*RRnR
RRX(R((s,/usr/local/lib/python2.7/test/test_shutil.pyt"test_existing_file_inside_dest_dirscCs;tjj|jdƒ}|jtjtj|j|ƒdS(Ntbar(RRRRWR*RRnR
(RRp((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_dont_move_dir_in_itselfscCs™tjtƒzqxjdgD]_\}}tjjt|ƒ}tjjt|ƒ}|jtj||ƒdd||fƒqWWdtjtdt	ƒXdS(Ntsrcdirssrcdir/destRÌs?_destinsrc() wrongly concluded that dst (%s) is not in src (%s)Rr(Rssrcdir/dest(
RR3RRRR@Rt
_destinsrcRRs(RRaRp((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_destinsrc_false_negative
s
cCsœtjtƒztxmddgD]_\}}tjjt|ƒ}tjjt|ƒ}|jtj||ƒdd||fƒqWWdtjtdt	ƒXdS(	NRssrc/dests
srcdir.newRÌs;_destinsrc() wrongly concluded that dst (%s) is in src (%s)Rr(Rssrc/dest(Rs
srcdir.new(
RR3RRRRRR RRs(RRaRp((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_destinsrc_false_positives
(RõRöR
RRRRRRRRRRRRR÷RøRRRRRRR!R"(((s,/usr/local/lib/python2.7/test/test_shutil.pyRÿ•s$										
			!			tTestCopyFilecBsceZeZdefd„ƒYZd„Zd„Zd„Zd„Z	d„Z
d„Zd„ZRS(	tFauxcBsDeZeZdZeZeed„Zd„Z	d„Z
d„ZRS(cCs||_||_dS(N(t_raise_in_exitt_suppress_at_exit(Rt
raise_in_exittsuppress_at_exit((s,/usr/local/lib/python2.7/test/test_shutil.pyt__init__.s	cGsdS(NR’((RR{((s,/usr/local/lib/python2.7/test/test_shutil.pyRL1scCs
t|_dS(N(Rst_entered(R((s,/usr/local/lib/python2.7/test/test_shutil.pyt	__enter__3scCs:|||f|_|jr3t|_tdƒ‚n|jS(NsCannot close(t_exited_withR%Rst_raisedtIOErrorR&(Rtexc_typetexc_valtexc_tb((s,/usr/local/lib/python2.7/test/test_shutil.pyt__exit__5s
		N(RõRötFalseR*RR,R-RsR)RLR+R2(((s,/usr/local/lib/python2.7/test/test_shutil.pyR$*s		cCs|jrt`ndS(N(t_deleteRR (R((s,/usr/local/lib/python2.7/test/test_shutil.pyR<s	cCs|t_t|_dS(N(RR RsR4(RRC((s,/usr/local/lib/python2.7/test/test_shutil.pyt_set_shutil_open@s	cCs6dd„}|j|ƒ|jttjddƒdS(NRlcSs|dkrtdƒ‚ndS(NtsrcfilesCannot open "srcfile"(R.(R,tmode((s,/usr/local/lib/python2.7/test/test_shutil.pyt_openEsR6tdestfile(R5R*R.RRo(RR8((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_w_source_open_failsDs
csƒ|jƒ‰d‡fd†}|j|ƒtjddƒ|jˆjƒ|jˆjdtkƒ|jˆjdj	dƒdS(	NRlcs/|dkrˆS|dkr+tdƒ‚ndS(NR6R9sCannot open "destfile"(R.(R,R7(R6(s,/usr/local/lib/python2.7/test/test_shutil.pyR8Rs
R6R9iisCannot open "destfile"(sCannot open "destfile"(
R$R5RRoR@R*R,R.R9R{(RR8((R6s,/usr/local/lib/python2.7/test/test_shutil.pyttest_w_dest_open_failsNs
csµ|jƒ‰|jtƒ‰d‡‡fd†}|j|ƒtjddƒ|jˆjƒ|jˆjƒ|jˆjƒ|jˆjdt	kƒ|j
ˆjdjdƒdS(	NRlcs$|dkrˆS|dkr ˆSdS(NR6R9((R,R7(R9R6(s,/usr/local/lib/python2.7/test/test_shutil.pyR8fs
R6R9iisCannot close(sCannot close(R$RsR5RRoR@R*R-R,R.R9R{(RR8((R9R6s,/usr/local/lib/python2.7/test/test_shutil.pyttest_w_dest_close_failsas
cs´|jtƒ‰|jƒ‰d‡‡fd†}|j|ƒ|jttjddƒ|jˆjƒ|jˆjƒ|j	ˆj
ƒ|jˆjddkƒ|jˆj
ƒdS(NRlcs$|dkrˆS|dkr ˆSdS(NR6R9((R,R7(R9R6(s,/usr/local/lib/python2.7/test/test_shutil.pyR8|s
R6R9i(
R$RsR5R*R.RRoR@R*RR-R,R(RR8((R9R6s,/usr/local/lib/python2.7/test/test_shutil.pyttest_w_source_close_failsws
	cCsµtjƒ|_tjjtjj|jƒtjj|jƒjƒƒ}|j	|j|ƒz0t
j|j|ƒ|jtjj
|ƒƒWdtjj|ƒr°tj|ƒnXdS(N(R&R'RWRRRRVR˜tuppertassertNotEqualRR
R@RTRURB(RRX((s,/usr/local/lib/python2.7/test/test_shutil.pyttest_move_dir_caseinsensitives	(
RõRöR3R4tobjectR$RR5R:R;R<R=R@(((s,/usr/local/lib/python2.7/test/test_shutil.pyR#&s			
			cCstjtttƒdS(N(R™trun_unittestRRÿR#(((s,/usr/local/lib/python2.7/test/test_shutil.pyt	test_main st__main__()R÷RR&RûR5Rtos.pathRˆR³tdistutils.spawnRRRRRRœtwarningsRèRR™ttest.test_supportRRRRwRÖRØRsRÕtImportErrorR3RýRR¸RþtTestCaseRRÿR#RCRõ(((s,/usr/local/lib/python2.7/test/test_shutil.pyt<module>sN"







ÿÿl‘z	

Zerion Mini Shell 1.0