[ Avaa Bypassed ]




Upload:

Command:

hmhc3928@3.147.49.19: ~ $


��Yf�5�@sedZddlmZddlmZddlZddddd	d
didd
iZdddiddiZdddiddiZ	dddiddiZ
dddddd
diddiZdddiddiZdddiddiZ
ddddddddd hd
didd!iZdd"ddd#d
didd$iZdd%ddd&d'd(d)d*gd
didd+iZdd,didd-iZdd.didd/iZdd0didd1iZdd2didd3iZdd4didd5iZdd6didd7iZdd8didd9iZdd:didd;iZdd<didd=iZdd>didd?iZdd@diddAiZddBdiddCiZddDdiddEiZddFdddGdHdIdJd
diddKiZddLdiddMiZddNdiddOiZ ddPdiddQiZ!ddRdiddSiZ"dTdU�Z#e$dVkrae#�dS)Wa�Run human tests of Idle's window, dialog, and popup widgets.

run(*tests)
Create a master Tk window.  Within that, run each callable in tests
after finding the matching test spec in this file.  If tests is empty,
run an htest for each spec dict in this file after finding the matching
callable in the module named in the spec.  Close the window to skip or
end the test.

In a tested module, let X be a global name bound to a callable (class
or function) whose .__name__ attrubute is also X (the usual situation).
The first parameter of X must be 'parent'.  When called, the parent
argument will be the root window.  X must create a child Toplevel
window (or subclass thereof).  The Toplevel may be a test widget or
dialog, in which case the callable is the corresonding class.  Or the
Toplevel may contain the widget to be tested or set up a context in
which a test widget is invoked.  In this latter case, the callable is a
wrapper function that sets up the Toplevel and other objects.  Wrapper
function names, such as _editor_window', should start with '_'.


End the module with

if __name__ == '__main__':
    <unittest, if there is one>
    from idlelib.idle_test.htest import run
    run(X)

To have wrapper functions and test invocation code ignored by coveragepy
reports, put '# htest #' on the def statement header line.

def _wrapper(parent):  # htest #

Also make sure that the 'if __name__' line matches the above.  Then have
make sure that .coveragerc includes the following.

[report]
exclude_lines =
    .*# htest #
    if __name__ == .__main__.:

(The "." instead of "'" is intentional and necessary.)


To run any X, this file must contain a matching instance of the
following template, with X.__name__ prepended to '_spec'.
When all tests are run, the prefix is use to get X.

_spec = {
    'file': '',
    'kwds': {'title': ''},
    'msg': ""
    }

file (no .py): run() imports file.py.
kwds: augmented with {'parent':root} and passed to X as **kwds.
title: an example kwd; some widgets need this, delete if not.
msg: master window hints about testing the widget.


Modules and classes not being tested at the moment:
PyShell.PyShellEditorWindow
Debugger.Debugger
AutoCompleteWindow.AutoCompleteWindow
OutputWindow.OutputWindow (indirectly being tested with grep test)
�)�
import_module)�_initializeTkVariantTestsN�fileZaboutDialog�kwds�titlezaboutDialog testZ_htestT�msgzaTest every button. Ensure Python, TK and IDLE versions are correctly displayed.
 [Close] to exit.Z
CallTipWindowzHTyping '(' should display a calltip.
Typing ') should hide the calltip.
ZClassBrowserz�Inspect names of module, class(with superclass if applicable), methods and functions.
Toggle nested items.
Double clicking on items prints a traceback for an exception that is ignored.ZColorDelegatorz�The text is sample Python code.
Ensure components like comments, keywords, builtins,
string, definitions, and break are correctly colored.
The default color scheme is in idlelib/config-highlight.defZconfigDialogZConfigDialogTesta�IDLE preferences dialog.
In the 'Fonts/Tabs' tab, changing font face, should update the font face of the text in the area below it.
In the 'Highlighting' tab, try different color schemes. Clicking items in the sample program should update the choices above it.
In the 'Keys', 'General' and 'Extensions' tabs, test settingsof interest.
[Ok] to close the dialog.[Apply] to apply the settings and and [Cancel] to revert all changes.
Re-run the test to ensure changes made have persisted.ZdynOptionMenuWidgetz�Select one of the many options in the 'old option set'.
Click the button to change the option set.
Select one of the many options in the 'new option set'.ZEditorWindowz>Test editor functions of interest.
Best to close editor first.ZconfigSectionNameDialogzGet Name�messagezEnter somethingZ
used_names�abcz�After the text entered with [Ok] is stripped, <nothing>, 'abc', or more that 30 chars are errors.
Close 'Get Name' with a valid entry (printed to Shell), [Cancel], or [X]ZconfigHelpSourceEditzGet helpsourcea%Enter menu item name and help file path
 <nothing> and more than 30 chars are invalid menu item names.
<nothing>, file does not exist are invalid path items.
Test for incomplete web address for help file path.
A valid entry will be printed to shell with [0k].
[Cancel] will print None to shellZkeybindingDialogzTest keybindings�actionz
find-againZcurrentKeySequences�z�Test for different key modifier sequences.
<nothing> is invalid.
No modifier key is invalid.
Shift key with [a-z],[0-9], function key, move key, tab, spaceis invalid.
No validity checking if advanced key binding entry is used.Z
GrepDialogz�Click the 'Show GrepDialog' button.
Test the various 'Find-in-files' functions.
The results should be displayed in a new '*Output*' window.
'Right-click'->'Goto file/line' anywhere in the search results should open that file 
in a new EditorWindow.Z	IOBindingaTest the following bindings.
<Control-o> to open file from dialog.
Edit the file.
<Control-p> to print the file.
<Control-s> to save the file.
<Alt-s> to save-as another file.
<Control-c> to save-copy-as another file.
Check that changes were saved by opening the file elsewhere.Z	MultiCallaThe following actions should trigger a print to console or IDLE Shell.
Entering and leaving the text area, key entry, <Control-Key>,
<Alt-Key-a>, <Control-Key-a>, <Alt-Control-Key-a>, 
<Control-Button-1>, <Alt-Button-1> and focusing out of the window
are sequences to be tested.ZMultiStatusBarzjEnsure presence of multi-status bar below text area.
Click 'Update Status' to change the multi-status textZ
ObjectBrowserz�Double click on items upto the lowest level.
Attributes of the objects and related information will be displayed side-by-side at each level.ZPathBrowserz�Test for correct display of all paths in sys.path.
Toggle nested items upto the lowest level.
Double clicking on an item prints a traceback
for an exception that is ignored.Z
Percolatora@There are two tracers which can be toggled using a checkbox.
Toggling a tracer 'on' by checking it should print traceroutput to the console or to the IDLE shell.
If both the tracers are 'on', the output from the tracer which was switched 'on' later, should be printed first
Test for actions like text entry, and removal.Z
ReplaceDialogz�Click the 'Replace' button.
Test various replace options in the 'Replace dialog'.
Click [Close] or [X] to close the 'Replace Dialog'.ZSearchDialogz�Click the 'Search' button.
Test various search options in the 'Search dialog'.
Click [Close] or [X] to close the 'Search Dialog'.ZScrolledListz�You should see a scrollable list of items
Selecting (clicking) or double clicking an item prints the name to the console or Idle shell.
Right clicking an item will display a popup.�helpzPIf the help text displays, this works.
Text is selectable. Window is scrollable.ZStackViewerz�A stacktrace for a NameError exception.
Expand 'idlelib ...' and '<locals>'.
Check that exc_value, exc_tb, and exc_type are correct.
Ztabbedpagesz�Toggle between the two tabs 'foo' and 'bar'
Add a tab by entering a suitable name for it.
Remove an existing tab by entering its name.
Remove all existing tabs.
<nothing> is an invalid add page and remove page name.
ZtextViewz
Test textView�textz-The quick brown fox jumps over the lazy dog.
�#zNTest for read-only property of text.
Text is selectable. Window is scrollable.ZToolTipzPPlace mouse cursor over both the buttons
A tooltip should appear with some text.Z
TreeWidgetzDThe canvas is scrollable.
Click on folders upto to the lowest level.Z
UndoDelegatorz�Click [Undo] to undo any action.
Click [Redo] to redo any action.
Click [Dump] to dump the current state by printing to the console or the IDLE shell.
ZWidgetRedirectorzEEvery text insert should be printed to the console.or the IDLE shell.c	s�tj���jd��jdd�t��tj�dd�}|j�tj|dd���jd�j	d�dd	d
ddd
�tj
|d�j�}�jd|j
�|jdddddd��jdddddd�g�|rIx�|D]:}t�|jd}|j|d<�j||f�qWn�x�t�j�D]q\}}|jd�rY|dd&��|}�|d<td|d�}t|��}�j||f�qYWtjd��d�d��������fdd �}��fd!d"�}	tj�d#�d|	�}
|
j�tj�d$d%d|���j�|��j�dS)'Nz
IDLE htestrZpadx�
ZwrapZwordZbgZreliefZflatZheight��width�FZcommandZyscrollcommandZside�rightZfill�y�expandF�leftZbothT�_spec�name�zidlelib.rrcs�t��dkr�j��j�\}�|d���d<�jd|d��jdd��jdd	��jd|d
��jdd�dS)N�r�parentzTest r�stateZnormalz1.0�endrZdisabled)�lenZpack_forget�pop�set�	configureZdelete�insert)�	test_spec)�callable_object�next_button�root�	test_kwds�	test_list�	test_namer
��</opt/alt/python35/lib64/python3.5/idlelib/idle_test/htest.py�nextts


zrun.<locals>.nextcs6���}yt|j�Wntk
r1YnXdS)N)�print�result�AttributeError)Zwidget)r$r'r*r+�run_test�s

zrun.<locals>.run_testZtextvariabler
ZNext���)�tkZTkrZ	resizablerZFrameZpackZTextr!ZcgetZ	ScrollbarZyview�configr �globals�__name__�append�items�endswithr�getattrZ	StringVarZButtonZmainloop)ZtestsZ
frameLabelZ	scrollbarZtestr#�k�d�modr,r0Zbuttonr*)r$r%r&r'r(r)r
r+�runPsJ


+


$

r=�__main__)%�__doc__�	importlibrZidlelib.macosxSupportrZtkinterr2ZAboutDialog_specZ_calltip_window_specZ_class_browser_specZ_color_delegator_specZConfigDialog_specZ_dyn_option_menu_specZ_editor_window_specZGetCfgSectionNameDialog_specZGetHelpSourceDialog_specZGetKeysDialog_specZ_grep_dialog_specZ_io_binding_specZ_multi_call_specZ_multistatus_bar_specZ_object_browser_specZ_path_browser_specZ_percolator_specZ_replace_dialog_specZ_search_dialog_specZ_scrolled_list_specZshow_idlehelp_specZ_stack_viewer_specZ_tabbed_pages_specZTextViewer_specZ
_tooltip_specZ_tree_widget_specZ_undo_delegator_specZ_widget_redirector_specr=r5r*r*r*r+�<module>Bs�									
						
	C

Filemanager

Name Type Size Permission Actions
__init__.cpython-35.opt-1.pyc File 823 B 0644
__init__.cpython-35.opt-2.pyc File 496 B 0644
__init__.cpython-35.pyc File 823 B 0644
htest.cpython-35.opt-1.pyc File 11.44 KB 0644
htest.cpython-35.opt-2.pyc File 9.17 KB 0644
htest.cpython-35.pyc File 11.44 KB 0644
mock_idle.cpython-35.opt-1.pyc File 2.4 KB 0644
mock_idle.cpython-35.opt-2.pyc File 1.71 KB 0644
mock_idle.cpython-35.pyc File 2.4 KB 0644
mock_tk.cpython-35.opt-1.pyc File 11.12 KB 0644
mock_tk.cpython-35.opt-2.pyc File 6.29 KB 0644
mock_tk.cpython-35.pyc File 11.12 KB 0644
test_autocomplete.cpython-35.opt-1.pyc File 4.95 KB 0644
test_autocomplete.cpython-35.opt-2.pyc File 4.93 KB 0644
test_autocomplete.cpython-35.pyc File 4.95 KB 0644
test_autoexpand.cpython-35.opt-1.pyc File 4.13 KB 0644
test_autoexpand.cpython-35.opt-2.pyc File 4.06 KB 0644
test_autoexpand.cpython-35.pyc File 4.13 KB 0644
test_calltips.cpython-35.opt-1.pyc File 10.01 KB 0644
test_calltips.cpython-35.opt-2.pyc File 9.88 KB 0644
test_calltips.cpython-35.pyc File 10.09 KB 0644
test_config_help.cpython-35.opt-1.pyc File 4.31 KB 0644
test_config_help.cpython-35.opt-2.pyc File 4.23 KB 0644
test_config_help.cpython-35.pyc File 4.31 KB 0644
test_config_name.cpython-35.opt-1.pyc File 3.16 KB 0644
test_config_name.cpython-35.opt-2.pyc File 3.08 KB 0644
test_config_name.cpython-35.pyc File 3.16 KB 0644
test_configdialog.cpython-35.opt-1.pyc File 1.43 KB 0644
test_configdialog.cpython-35.opt-2.pyc File 1.27 KB 0644
test_configdialog.cpython-35.pyc File 1.43 KB 0644
test_delegator.cpython-35.opt-1.pyc File 1.1 KB 0644
test_delegator.cpython-35.opt-2.pyc File 1.09 KB 0644
test_delegator.cpython-35.pyc File 1.1 KB 0644
test_editmenu.cpython-35.opt-1.pyc File 2.88 KB 0644
test_editmenu.cpython-35.opt-2.pyc File 2.48 KB 0644
test_editmenu.cpython-35.pyc File 2.88 KB 0644
test_editor.cpython-35.opt-1.pyc File 1.19 KB 0644
test_editor.cpython-35.opt-2.pyc File 1.17 KB 0644
test_editor.cpython-35.pyc File 1.19 KB 0644
test_formatparagraph.cpython-35.opt-1.pyc File 12.41 KB 0644
test_formatparagraph.cpython-35.opt-2.pyc File 11.65 KB 0644
test_formatparagraph.cpython-35.pyc File 12.41 KB 0644
test_grep.cpython-35.opt-1.pyc File 3.08 KB 0644
test_grep.cpython-35.opt-2.pyc File 2.54 KB 0644
test_grep.cpython-35.pyc File 3.08 KB 0644
test_help_about.cpython-35.opt-1.pyc File 1.96 KB 0644
test_help_about.cpython-35.opt-2.pyc File 1.82 KB 0644
test_help_about.cpython-35.pyc File 1.96 KB 0644
test_hyperparser.cpython-35.opt-1.pyc File 8 KB 0644
test_hyperparser.cpython-35.opt-2.pyc File 7.81 KB 0644
test_hyperparser.cpython-35.pyc File 8 KB 0644
test_idlehistory.cpython-35.opt-1.pyc File 6.72 KB 0644
test_idlehistory.cpython-35.opt-2.pyc File 6.57 KB 0644
test_idlehistory.cpython-35.pyc File 6.72 KB 0644
test_io.cpython-35.opt-1.pyc File 8.76 KB 0644
test_io.cpython-35.opt-2.pyc File 8.75 KB 0644
test_io.cpython-35.pyc File 8.76 KB 0644
test_parenmatch.cpython-35.opt-1.pyc File 4.06 KB 0644
test_parenmatch.cpython-35.opt-2.pyc File 3.61 KB 0644
test_parenmatch.cpython-35.pyc File 4.06 KB 0644
test_pathbrowser.cpython-35.opt-1.pyc File 1.31 KB 0644
test_pathbrowser.cpython-35.opt-2.pyc File 1.29 KB 0644
test_pathbrowser.cpython-35.pyc File 1.31 KB 0644
test_percolator.cpython-35.opt-1.pyc File 5.18 KB 0644
test_percolator.cpython-35.opt-2.pyc File 5.13 KB 0644
test_percolator.cpython-35.pyc File 5.18 KB 0644
test_replacedialog.cpython-35.opt-1.pyc File 7.5 KB 0644
test_replacedialog.cpython-35.opt-2.pyc File 7.43 KB 0644
test_replacedialog.cpython-35.pyc File 7.5 KB 0644
test_rstrip.cpython-35.opt-1.pyc File 1.55 KB 0644
test_rstrip.cpython-35.opt-2.pyc File 1.54 KB 0644
test_rstrip.cpython-35.pyc File 1.55 KB 0644
test_searchdialog.cpython-35.opt-1.pyc File 2.42 KB 0644
test_searchdialog.cpython-35.opt-2.pyc File 2.34 KB 0644
test_searchdialog.cpython-35.pyc File 2.42 KB 0644
test_searchdialogbase.cpython-35.opt-1.pyc File 5.79 KB 0644
test_searchdialogbase.cpython-35.opt-2.pyc File 5.58 KB 0644
test_searchdialogbase.cpython-35.pyc File 5.79 KB 0644
test_searchengine.cpython-35.opt-1.pyc File 10.7 KB 0644
test_searchengine.cpython-35.opt-2.pyc File 10.61 KB 0644
test_searchengine.cpython-35.pyc File 10.7 KB 0644
test_text.cpython-35.opt-1.pyc File 6.86 KB 0644
test_text.cpython-35.opt-2.pyc File 6.84 KB 0644
test_text.cpython-35.pyc File 6.86 KB 0644
test_textview.cpython-35.opt-1.pyc File 3.86 KB 0644
test_textview.cpython-35.opt-2.pyc File 3.53 KB 0644
test_textview.cpython-35.pyc File 3.86 KB 0644
test_undodelegator.cpython-35.opt-1.pyc File 4.57 KB 0644
test_undodelegator.cpython-35.opt-2.pyc File 4.3 KB 0644
test_undodelegator.cpython-35.pyc File 4.57 KB 0644
test_warning.cpython-35.opt-1.pyc File 2.84 KB 0644
test_warning.cpython-35.opt-2.pyc File 2.5 KB 0644
test_warning.cpython-35.pyc File 2.84 KB 0644
test_widgetredir.cpython-35.opt-1.pyc File 5.49 KB 0644
test_widgetredir.cpython-35.opt-2.pyc File 5.4 KB 0644
test_widgetredir.cpython-35.pyc File 5.49 KB 0644