__  __    __   __  _____      _            _          _____ _          _ _ 
 |  \/  |   \ \ / / |  __ \    (_)          | |        / ____| |        | | |
 | \  / |_ __\ V /  | |__) | __ ___   ____ _| |_ ___  | (___ | |__   ___| | |
 | |\/| | '__|> <   |  ___/ '__| \ \ / / _` | __/ _ \  \___ \| '_ \ / _ \ | |
 | |  | | |_ / . \  | |   | |  | |\ V / (_| | ||  __/  ____) | | | |  __/ | |
 |_|  |_|_(_)_/ \_\ |_|   |_|  |_| \_/ \__,_|\__\___| |_____/|_| |_|\___V 2.1
 if you need WebShell for Seo everyday contact me on Telegram
 Telegram Address : @jackleet
        
        
For_More_Tools: Telegram: @jackleet | Bulk Smtp support mail sender | Business Mail Collector | Mail Bouncer All Mail | Bulk Office Mail Validator | Html Letter private



Upload:

Command:

aptanhua@216.73.216.7: ~ $
3

� fq �@s�dZddlmZddlZddlmZed�ddlmZmZddl	m
Z
ddlmZddl
jZejZejZGd	d
�d
ej�Zedkr�ejdd
�dS)zTest replace, coverage 78%.�)�
ReplaceDialogN)�requiresZgui)�Tk�Text)�Mock)�Mboxc@steZdZedd��Zedd��Zdd�Zdd�Zd	d
�Zdd�Z	d
d�Z
dd�Zdd�Zdd�Z
dd�Zdd�ZdS)�ReplaceDialogTestcCszt�|_|jj�tt_tj|j�|_t|j|j�|_	dd�|j	_
t�|j	_t
|j�|_t�|j_t�|j_|j|j	_dS)NcSsdS)N�r	r	r	�C/opt/alt/python36/lib64/python3.6/idlelib/idle_test/test_replace.py�<lambda>sz.ReplaceDialogTest.setUpClass.<locals>.<lambda>)r�rootZwithdrawr�se�tkMessageBoxZSearchEngine�enginer�dialogZbellr�okr�textZundo_block_startZundo_block_stop)�clsr	r	r
�
setUpClasss



zReplaceDialogTest.setUpClasscCs$tt_|`|`|`|jj�|`dS)N)�	orig_mboxr
rrrrrZdestroy)rr	r	r
�
tearDownClass!s
zReplaceDialogTest.tearDownClasscCs|jjdd�dS)N�insertzThis is a sample sTring)rr)�selfr	r	r
�setUp(szReplaceDialogTest.setUpcCs�|jjjd�|jjjd�|jjjd�|jjjd�|jjjd�|jjjd�|jj	jd�dt
_dt
_|j
jdd�dS)N�FTz1.0�end)r�patvar�setr�replvar�wordvar�casevar�revar�wrapvar�backvar�	showerror�title�messager�delete)rr	r	r
�tearDown+szReplaceDialogTest.tearDowncCs�|j}|j}|jj}|jj}|jj}|jjd�||jj�|j	��|j
d�|j
d�|�||j	dd�d�|jdd�|j
d�|j
d�|�||j	d	d
�d�|j
d�|j
d�|�||j	d
d�d�|jdd�|jdd�|j	dd�}|j
d�|�|j	dd�}|||�|jdd�|j
d�|j
d�|�||j	d�d�||j	d�d�|�||j	d�d�||j	d�d�|j	dd�}|�|j	dd�}|||�|j	dd�}|j
d�|�|j	dd�}|||�|jj
d�dS)NZasdf�az1.8z1.12rz1.0�is�helloz1.2z1.7�stringZworldz1.23z1.28rz
line42:z
[a-z][\d]+z1.9�i�jz2.1�foobarr)r�assertEqualrrrr�
replace_itZsetpatZgetpat�getr�mark_setrZfind_it)rr�equal�pv�rv�replace�before_text�
after_textr	r	r
�test_replace_simple7s\












z%ReplaceDialogTest.test_replace_simplecCs�|j}|j}|jj}|jj}|jj}|jjjd�|j	dd�|jd�|jd�|�||j
d�d�||j
d�d�|�||j
d�d�||j
d�d�|�||j
d�d�|j	dd	�|jd
�|j
dd�}|�|j
dd�}|||�dS)
NFrz1.4r-r.z1.2z1.5z1.20z1.8r*z1.0r)rr0rrrrr1r"rr3r2)rrr4r5r6r7r8r9r	r	r
�test_replace_wrap_around}s.


z*ReplaceDialogTest.test_replace_wrap_aroundcCst|j}|j}|jj}|jj}|jj}|jjjd�|jd�|jd�|�||j	dd�d�||j	dd�d�dS)	NTr*r+z1.0z1.4�Thisz1.5z1.10)
rr0rrrrr1rrr2)rrr4r5r6r7r	r	r
�test_replace_whole_word�s

z)ReplaceDialogTest.test_replace_whole_wordcCs�|j}|j}|jj}|jj}|jj}|jjjd�|jj	dd�}|jd�|jd�|�|jj	dd�}|||�|jd�|�||j	dd�d�dS)NTz1.0r�this�thatr<z1.4)
r0rrrrrr1r rr2)rr4rr5r6r7r8r9r	r	r
�test_replace_match_case�s



z)ReplaceDialogTest.test_replace_match_casecCsJ|j}|j}|jj}|jj}|jj}|jjjd�|j	dd�}|jd�|jd�|�|j	dd�}|||�|j
dd�|�||j	dd	�d
�|jd�|�|jdtj
�|jd
tj�|jd�|�|jdtj
�|jdtj�dt_
dt_|jd�|jd�|�|jdtj
�|jdtj�|jjd�||j	�d�dS)NTz1.0rz
[a-z][\d]+r+rz
line42z2.0z2.8Zlinhellor�error�Emptyz[\d�Patternz[a]ztest\zInvalid Replace Expression�?z\?)r0rrrrrr1r!rr2r�assertInr$r%r&Zsetcookedpat)rr4rr5r6r7r8r9r	r	r
�test_replace_regex�s@






z$ReplaceDialogTest.test_replace_regexcCs�|j}|j}|jj}|jj}|jj}|jjjd�|j	dd�|jd�|jd�|�||j
dd�d�||j
dd	�d�|�||j
d
d�d�|�||j
dd
�d�dS)NTrz
is as r*�wasz1.2z1.4z2.0z2.3z1.5z1.8)r0rrrrrr1r#rrr2)rr4rr5r6r7r	r	r
�test_replace_backwards�s 

z(ReplaceDialogTest.test_replace_backwardscCs�|j}|jj}|jj}|jj}|jdd�|jd|jdd�d�|jd�|jd�|�|j	d|jdd��|jj
jd�|jd	�|�|jd
tj
�|jdtj�|jd�|jd
�|�|jj
jd�|jd�|jd�|�dS)Nr�
z1.0r�dr*rGTrrArBz[s][T]�\Fztext which is not presentr/)rrrrr�replace_allrr2rZassertNotInr!rEr$r%r&)rrr5r6rLr	r	r
�test_replace_all�s,






z"ReplaceDialogTest.test_replace_allcCsr|j}|jj}|jj}|jj}|j}|jd�|jd�|�||jdd�d�|jj	jd�|jd�|�dS)Nr<rGz	sel.firstzsel.lastTr)
rrrrrZdefault_commandr0rr2r!)rrr5r6Zreplace_findr4r	r	r
�test_default_commands


z&ReplaceDialogTest.test_default_commandN)�__name__�
__module__�__qualname__�classmethodrrrr(r:r;r=r@rFrHrMrNr	r	r	r
rsF)r�__main__�)�	verbosity)�__doc__Zidlelib.replacerZunittestZtest.supportrZtkinterrrZ
unittest.mockrZidlelib.idle_test.mock_tkrZidlelib.searchengineZsearchenginer
rrr$ZTestCaserrO�mainr	r	r	r
�<module>s


Filemanager

Name Type Size Permission Actions
__init__.cpython-36.opt-1.pyc File 850 B 0644
__init__.cpython-36.opt-2.pyc File 463 B 0644
__init__.cpython-36.pyc File 850 B 0644
htest.cpython-36.opt-1.pyc File 11 KB 0644
htest.cpython-36.opt-2.pyc File 8.74 KB 0644
htest.cpython-36.pyc File 11 KB 0644
mock_idle.cpython-36.opt-1.pyc File 2.53 KB 0644
mock_idle.cpython-36.opt-2.pyc File 1.66 KB 0644
mock_idle.cpython-36.pyc File 2.53 KB 0644
mock_tk.cpython-36.opt-1.pyc File 10.54 KB 0644
mock_tk.cpython-36.opt-2.pyc File 5.72 KB 0644
mock_tk.cpython-36.pyc File 10.54 KB 0644
template.cpython-36.opt-1.pyc File 1.02 KB 0644
template.cpython-36.opt-2.pyc File 994 B 0644
template.cpython-36.pyc File 1.02 KB 0644
test_autocomplete.cpython-36.opt-1.pyc File 4.51 KB 0644
test_autocomplete.cpython-36.opt-2.pyc File 4.44 KB 0644
test_autocomplete.cpython-36.pyc File 4.51 KB 0644
test_autocomplete_w.cpython-36.opt-1.pyc File 1.26 KB 0644
test_autocomplete_w.cpython-36.opt-2.pyc File 1.19 KB 0644
test_autocomplete_w.cpython-36.pyc File 1.26 KB 0644
test_autoexpand.cpython-36.opt-1.pyc File 3.82 KB 0644
test_autoexpand.cpython-36.opt-2.pyc File 3.75 KB 0644
test_autoexpand.cpython-36.pyc File 3.82 KB 0644
test_browser.cpython-36.opt-1.pyc File 8.66 KB 0644
test_browser.cpython-36.opt-2.pyc File 8.52 KB 0644
test_browser.cpython-36.pyc File 8.66 KB 0644
test_calltip.cpython-36.opt-1.pyc File 11.14 KB 0644
test_calltip.cpython-36.opt-2.pyc File 10.97 KB 0644
test_calltip.cpython-36.pyc File 11.21 KB 0644
test_calltip_w.cpython-36.opt-1.pyc File 1.22 KB 0644
test_calltip_w.cpython-36.opt-2.pyc File 1.15 KB 0644
test_calltip_w.cpython-36.pyc File 1.22 KB 0644
test_codecontext.cpython-36.opt-1.pyc File 10.15 KB 0644
test_codecontext.cpython-36.opt-2.pyc File 10.09 KB 0644
test_codecontext.cpython-36.pyc File 10.15 KB 0644
test_colorizer.cpython-36.opt-1.pyc File 2.17 KB 0644
test_colorizer.cpython-36.opt-2.pyc File 2.11 KB 0644
test_colorizer.cpython-36.pyc File 2.17 KB 0644
test_config.cpython-36.opt-1.pyc File 25.25 KB 0644
test_config.cpython-36.opt-2.pyc File 24.42 KB 0644
test_config.cpython-36.pyc File 25.25 KB 0644
test_config_key.cpython-36.opt-1.pyc File 4.53 KB 0644
test_config_key.cpython-36.opt-2.pyc File 4.41 KB 0644
test_config_key.cpython-36.pyc File 4.53 KB 0644
test_configdialog.cpython-36.opt-1.pyc File 36.63 KB 0644
test_configdialog.cpython-36.opt-2.pyc File 35.69 KB 0644
test_configdialog.cpython-36.pyc File 36.63 KB 0644
test_debugger.cpython-36.opt-1.pyc File 1.06 KB 0644
test_debugger.cpython-36.opt-2.pyc File 1 KB 0644
test_debugger.cpython-36.pyc File 1.06 KB 0644
test_debugger_r.cpython-36.opt-1.pyc File 697 B 0644
test_debugger_r.cpython-36.opt-2.pyc File 632 B 0644
test_debugger_r.cpython-36.pyc File 697 B 0644
test_debugobj.cpython-36.opt-1.pyc File 2.64 KB 0644
test_debugobj.cpython-36.opt-2.pyc File 2.58 KB 0644
test_debugobj.cpython-36.pyc File 2.64 KB 0644
test_debugobj_r.cpython-36.opt-1.pyc File 1.08 KB 0644
test_debugobj_r.cpython-36.opt-2.pyc File 1.02 KB 0644
test_debugobj_r.cpython-36.pyc File 1.08 KB 0644
test_delegator.cpython-36.opt-1.pyc File 1.04 KB 0644
test_delegator.cpython-36.opt-2.pyc File 1004 B 0644
test_delegator.cpython-36.pyc File 1.04 KB 0644
test_editmenu.cpython-36.opt-1.pyc File 2.75 KB 0644
test_editmenu.cpython-36.opt-2.pyc File 2.36 KB 0644
test_editmenu.cpython-36.pyc File 2.75 KB 0644
test_editor.cpython-36.opt-1.pyc File 1.96 KB 0644
test_editor.cpython-36.opt-2.pyc File 1.9 KB 0644
test_editor.cpython-36.pyc File 1.96 KB 0644
test_filelist.cpython-36.opt-1.pyc File 1.28 KB 0644
test_filelist.cpython-36.opt-2.pyc File 1.22 KB 0644
test_filelist.cpython-36.pyc File 1.28 KB 0644
test_grep.cpython-36.opt-1.pyc File 2.88 KB 0644
test_grep.cpython-36.opt-2.pyc File 2.34 KB 0644
test_grep.cpython-36.pyc File 2.88 KB 0644
test_help.cpython-36.opt-1.pyc File 1.37 KB 0644
test_help.cpython-36.opt-2.pyc File 1.25 KB 0644
test_help.cpython-36.pyc File 1.37 KB 0644
test_help_about.cpython-36.opt-1.pyc File 6.48 KB 0644
test_help_about.cpython-36.opt-2.pyc File 5.79 KB 0644
test_help_about.cpython-36.pyc File 6.48 KB 0644
test_history.cpython-36.opt-1.pyc File 6.16 KB 0644
test_history.cpython-36.opt-2.pyc File 5.98 KB 0644
test_history.cpython-36.pyc File 6.16 KB 0644
test_hyperparser.cpython-36.opt-1.pyc File 7.13 KB 0644
test_hyperparser.cpython-36.opt-2.pyc File 6.95 KB 0644
test_hyperparser.cpython-36.pyc File 7.13 KB 0644
test_iomenu.cpython-36.opt-1.pyc File 1.31 KB 0644
test_iomenu.cpython-36.opt-2.pyc File 1.26 KB 0644
test_iomenu.cpython-36.pyc File 1.31 KB 0644
test_macosx.cpython-36.opt-1.pyc File 3.76 KB 0644
test_macosx.cpython-36.opt-2.pyc File 3.36 KB 0644
test_macosx.cpython-36.pyc File 3.83 KB 0644
test_mainmenu.cpython-36.opt-1.pyc File 1.12 KB 0644
test_mainmenu.cpython-36.opt-2.pyc File 1.05 KB 0644
test_mainmenu.cpython-36.pyc File 1.12 KB 0644
test_multicall.cpython-36.opt-1.pyc File 1.48 KB 0644
test_multicall.cpython-36.opt-2.pyc File 1.42 KB 0644
test_multicall.cpython-36.pyc File 1.48 KB 0644
test_outwin.cpython-36.opt-1.pyc File 5.42 KB 0644
test_outwin.cpython-36.opt-2.pyc File 5.36 KB 0644
test_outwin.cpython-36.pyc File 5.42 KB 0644
test_paragraph.cpython-36.opt-1.pyc File 11.63 KB 0644
test_paragraph.cpython-36.opt-2.pyc File 10.83 KB 0644
test_paragraph.cpython-36.pyc File 11.63 KB 0644
test_parenmatch.cpython-36.opt-1.pyc File 3.84 KB 0644
test_parenmatch.cpython-36.opt-2.pyc File 3.44 KB 0644
test_parenmatch.cpython-36.pyc File 3.84 KB 0644
test_pathbrowser.cpython-36.opt-1.pyc File 3.21 KB 0644
test_pathbrowser.cpython-36.opt-2.pyc File 3.15 KB 0644
test_pathbrowser.cpython-36.pyc File 3.21 KB 0644
test_percolator.cpython-36.opt-1.pyc File 4.76 KB 0644
test_percolator.cpython-36.opt-2.pyc File 4.69 KB 0644
test_percolator.cpython-36.pyc File 4.76 KB 0644
test_pyparse.cpython-36.opt-1.pyc File 14.05 KB 0644
test_pyparse.cpython-36.opt-2.pyc File 13.99 KB 0644
test_pyparse.cpython-36.pyc File 14.05 KB 0644
test_pyshell.cpython-36.opt-1.pyc File 1.18 KB 0644
test_pyshell.cpython-36.opt-2.pyc File 1.12 KB 0644
test_pyshell.cpython-36.pyc File 1.18 KB 0644
test_query.cpython-36.opt-1.pyc File 14.69 KB 0644
test_query.cpython-36.opt-2.pyc File 13.9 KB 0644
test_query.cpython-36.pyc File 14.69 KB 0644
test_redirector.cpython-36.opt-1.pyc File 5 KB 0644
test_redirector.cpython-36.opt-2.pyc File 4.93 KB 0644
test_redirector.cpython-36.pyc File 5 KB 0644
test_replace.cpython-36.opt-1.pyc File 6.73 KB 0644
test_replace.cpython-36.opt-2.pyc File 6.67 KB 0644
test_replace.cpython-36.pyc File 6.73 KB 0644
test_rpc.cpython-36.opt-1.pyc File 1.61 KB 0644
test_rpc.cpython-36.opt-2.pyc File 1.55 KB 0644
test_rpc.cpython-36.pyc File 1.61 KB 0644
test_rstrip.cpython-36.opt-1.pyc File 1.46 KB 0644
test_rstrip.cpython-36.opt-2.pyc File 1.39 KB 0644
test_rstrip.cpython-36.pyc File 1.46 KB 0644
test_run.cpython-36.opt-1.pyc File 9.21 KB 0644
test_run.cpython-36.opt-2.pyc File 9.15 KB 0644
test_run.cpython-36.pyc File 9.21 KB 0644
test_runscript.cpython-36.opt-1.pyc File 1.29 KB 0644
test_runscript.cpython-36.opt-2.pyc File 1.22 KB 0644
test_runscript.cpython-36.pyc File 1.29 KB 0644
test_scrolledlist.cpython-36.opt-1.pyc File 1.05 KB 0644
test_scrolledlist.cpython-36.opt-2.pyc File 1009 B 0644
test_scrolledlist.cpython-36.pyc File 1.05 KB 0644
test_search.cpython-36.opt-1.pyc File 2.42 KB 0644
test_search.cpython-36.opt-2.pyc File 2.36 KB 0644
test_search.cpython-36.pyc File 2.42 KB 0644
test_searchbase.cpython-36.opt-1.pyc File 4.96 KB 0644
test_searchbase.cpython-36.opt-2.pyc File 4.9 KB 0644
test_searchbase.cpython-36.pyc File 4.96 KB 0644
test_searchengine.cpython-36.opt-1.pyc File 9.59 KB 0644
test_searchengine.cpython-36.opt-2.pyc File 9.53 KB 0644
test_searchengine.cpython-36.pyc File 9.59 KB 0644
test_squeezer.cpython-36.opt-1.pyc File 15.12 KB 0644
test_squeezer.cpython-36.opt-2.pyc File 13.6 KB 0644
test_squeezer.cpython-36.pyc File 15.12 KB 0644
test_stackviewer.cpython-36.opt-1.pyc File 1.5 KB 0644
test_stackviewer.cpython-36.opt-2.pyc File 1.44 KB 0644
test_stackviewer.cpython-36.pyc File 1.5 KB 0644
test_statusbar.cpython-36.opt-1.pyc File 1.52 KB 0644
test_statusbar.cpython-36.opt-2.pyc File 1.46 KB 0644
test_statusbar.cpython-36.pyc File 1.52 KB 0644
test_text.cpython-36.opt-1.pyc File 6.42 KB 0644
test_text.cpython-36.opt-2.pyc File 6.23 KB 0644
test_text.cpython-36.pyc File 6.42 KB 0644
test_textview.cpython-36.opt-1.pyc File 6.96 KB 0644
test_textview.cpython-36.opt-2.pyc File 6.65 KB 0644
test_textview.cpython-36.pyc File 6.96 KB 0644
test_tooltip.cpython-36.opt-1.pyc File 5.26 KB 0644
test_tooltip.cpython-36.opt-2.pyc File 5.25 KB 0644
test_tooltip.cpython-36.pyc File 5.26 KB 0644
test_tree.cpython-36.opt-1.pyc File 1.25 KB 0644
test_tree.cpython-36.opt-2.pyc File 1.19 KB 0644
test_tree.cpython-36.pyc File 1.25 KB 0644
test_undo.cpython-36.opt-1.pyc File 4.06 KB 0644
test_undo.cpython-36.opt-2.pyc File 3.85 KB 0644
test_undo.cpython-36.pyc File 4.06 KB 0644
test_warning.cpython-36.opt-1.pyc File 2.64 KB 0644
test_warning.cpython-36.opt-2.pyc File 2.3 KB 0644
test_warning.cpython-36.pyc File 2.64 KB 0644
test_window.cpython-36.opt-1.pyc File 1.56 KB 0644
test_window.cpython-36.opt-2.pyc File 1.5 KB 0644
test_window.cpython-36.pyc File 1.56 KB 0644
test_zoomheight.cpython-36.opt-1.pyc File 1.47 KB 0644
test_zoomheight.cpython-36.opt-2.pyc File 1.41 KB 0644
test_zoomheight.cpython-36.pyc File 1.47 KB 0644