/opt/alt/python27/lib64/python2.7/idlelib/idle_test
NameSizeModeActions
htest.py137790644editdlrm
htest.pyc126520644editdlrm
htest.pyo126520644editdlrm
mock_idle.py15970644editdlrm
mock_idle.pyc30090644editdlrm
mock_idle.pyo30090644editdlrm
mock_tk.py115740644editdlrm
mock_tk.pyc127130644editdlrm
mock_tk.pyo127130644editdlrm
README.txt54920644editdlrm
test_autocomplete.py49220644editdlrm
test_autocomplete.pyc61200644editdlrm
test_autocomplete.pyo61200644editdlrm
test_autoexpand.py41220644editdlrm
test_autoexpand.pyc49620644editdlrm
test_autoexpand.pyo49620644editdlrm
test_calltips.py71400644editdlrm
test_calltips.pyc127680644editdlrm
test_calltips.pyo127680644editdlrm
test_configdialog.py7820644editdlrm
test_configdialog.pyc17200644editdlrm
test_configdialog.pyo17200644editdlrm
test_config_name.py24720644editdlrm
test_config_name.pyc41810644editdlrm
test_config_name.pyo41810644editdlrm
test_delegator.py12940644editdlrm
test_delegator.pyc13580644editdlrm
test_delegator.pyo13580644editdlrm
test_editmenu.py31670644editdlrm
test_editmenu.pyc45690644editdlrm
test_editmenu.pyo45690644editdlrm
test_formatparagraph.py143440644editdlrm
test_formatparagraph.pyc147080644editdlrm
test_formatparagraph.pyo147080644editdlrm
test_grep.py27620644editdlrm
test_grep.pyc39030644editdlrm
test_grep.pyo39030644editdlrm
test_helpabout.py16110644editdlrm
test_helpabout.pyc24410644editdlrm
test_helpabout.pyo24410644editdlrm
test_hyperparser.py56840644editdlrm
test_hyperparser.pyc69420644editdlrm
test_hyperparser.pyo69420644editdlrm
test_idlehistory.py54950644editdlrm
test_idlehistory.pyc84800644editdlrm
test_idlehistory.pyo84800644editdlrm
test_io.py95050644editdlrm
test_io.pyc119490644editdlrm
test_io.pyo119490644editdlrm
test_parenmatch.py38220644editdlrm
test_parenmatch.pyc56640644editdlrm
test_parenmatch.pyo56640644editdlrm
test_pathbrowser.py9400644editdlrm
test_pathbrowser.pyc15370644editdlrm
test_pathbrowser.pyo15370644editdlrm
test_rstrip.py16130644editdlrm
test_rstrip.pyc18250644editdlrm
test_rstrip.pyo18250644editdlrm
test_searchdialogbase.py58630644editdlrm
test_searchdialogbase.pyc70350644editdlrm
test_searchdialogbase.pyo70350644editdlrm
test_searchengine.py114870644editdlrm
test_searchengine.pyc131170644editdlrm
test_searchengine.pyo131170644editdlrm
test_text.py67440644editdlrm
test_text.pyc83950644editdlrm
test_text.pyo83950644editdlrm
test_textview.py28020644editdlrm
test_textview.pyc47130644editdlrm
test_textview.pyo47130644editdlrm
test_warning.py27570644editdlrm
test_warning.pyc33900644editdlrm
test_warning.pyo33900644editdlrm
test_widgetredir.py41770644editdlrm
test_widgetredir.pyc66440644editdlrm
test_widgetredir.pyo66440644editdlrm
__init__.py6500644editdlrm
__init__.pyc9410644editdlrm
__init__.pyo9410644editdlrm
Edit: /opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyo (14708B)
ó Þ[ bc@s7ddlZddlmZddlmZddlmZmZddl m Z dej fd„ƒYZ dej fd „ƒYZ d ej fd „ƒYZd ej fd „ƒYZdej fd„ƒYZddd„ƒYZddd„ƒYZdej fd„ƒYZedkr3ejddddƒndS(iÿÿÿÿN(tFormatParagraph(t EditorWindow(tTktText(trequirest Is_Get_TestcBsGeZdZdZdZdZdZdZd„Zd„Z d„Z RS( sTest the is_ and get_ functionss# This is a commentsThis is not a comments# This is a comment s # This is a comments This is not a commentcCsI|jtjdƒƒ|jtjdƒƒ|jtj|jƒƒdS(Nts (t assertTruetfpt is_all_whitet assertFalset test_comment(tself((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyttest_is_all_whitescCsq|j}|tj|jƒdƒ|tj|jƒdƒ|tj|jƒdƒ|tj|jƒdƒdS(NRs (t assertEqualRt get_indentR ttrailingws_commenttleadingws_commenttleadingws_nocomment(R tEqual((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyttest_get_indents  cCsŠ|j}|tj|jƒdƒ|tj|jƒdƒ|tj|jƒdƒ|tj|jƒdƒ|tj|jƒdƒdS(Nt#s #s R(RRtget_comment_headerR RRRttest_nocomment(R R((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyttest_get_comment_headers  ( t__name__t __module__t__doc__R RRRRR RR(((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyR s  tFindTestcBs8eZdZed„ƒZd„Zd„Zd„ZRS(s`Test the find_paragraph function in FormatParagraph. Using the runcase() function, find_paragraph() is called with 'mark' set at multiple indexes before and inside the test paragraph. It appears that code with the same indentation as a quoted string is grouped as part of the same paragraph, which is probably incorrect behavior. cCs ddlm}|ƒ|_dS(Niÿÿÿÿ(R(tidlelib.idle_test.mock_tkRttext(tclsR((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyt setUpClass2sc Cs·|j}|jd|ƒx‡td|ƒD]v}t|jd|ƒjdƒdƒ}xGd|d|fD]2}d||f}|jtj||ƒ|ƒqiWq)W|j ddƒdS( Ns1.0is%d.endt.iis%d.%dtend( RtinserttrangetinttindextsplitRRtfind_paragraphtdelete( R t inserttexttstoplinetexpectedRtlinet linelengthtcolt tempindex((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pytruncase7s &$c Csdd}|j|dddd|dd!fƒd}|j|d d d d|d d !fƒd}|j|d d d d|d d!fƒd}|j|dd dd|d d!fƒd}|j|dd dd|d d!fƒd}|j|dd dd|d d!fƒd}|j|dd dd|d d!fƒd}|j|dd dd|d d!fƒdS(Ns;# Comment block with no blank lines before # Comment line is1.0s3.0Rii:sG # Comment block with whitespace line before and after # Comment line is2.0s4.0iiFsS # Indented comment block with whitespace before and after # Comment line s #iRs # Single line comment is4 # Single line comment with leading whitespace i3s0 # Comment immediately followed by code x = 42 i(s= # Indented comment immediately followed by code x = 42 i5s= # Comment immediately followed by indented code x = 42 i1(R1(R tcomment((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyttest_find_commentDs &&&&&&&c Csàd}|j|dddd|dd!fƒd}|j|d d d d|d d !fƒd}|j|d d d d|d d!fƒd}|j|dd dd|d d!fƒd}|j|dd dd|d d!fƒdS(Ns6"""String with no blank lines before String line """ is1.0s4.0Rii5sC """String with whitespace line before and after String line. """ is2.0s5.0iiBsV """Indented string with whitespace before and after Comment string. """ s iUs """Single line string.""" is3.0is8 """Single line string with leading whitespace.""" i7(R1(R t teststring((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyttest_find_paragraphzs&&&&(RRRt classmethodR R1R3R5(((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyR(s  6tReformatFunctionTestcBseZdZd„ZRS(s?Test the reformat_paragraph function without the editor window.cCs*|j}tj}d}||ddƒdƒ||ddƒdƒ|||dƒdƒ|||dƒdƒ|||d ƒd ƒ|||d ƒd ƒ|||d ƒdƒd }|||dƒdƒ|||dƒdƒ|||d ƒdƒ|||d ƒdƒ|||d ƒd ƒdS(Ns O hello worldt isHello worldis Hello worlds O hello worldiis O hello worldi i s O hello worlds O hello worlds O hello world(RRtreformat_paragraph(R Rtreformthw((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyttest_reformat_paragraph¢s   (RRRR<(((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyR7ŸstReformatCommentTestcBseZdZd„ZRS(s=Test the reformat_comment function without the editor window.cCsi|j}d}tj|ddƒ}d}|||ƒd}tj|ddƒ}d}|||ƒdS(Nsu """this is a test of a reformat for a triple quoted string will it reformat to less than 70 characters for me?"""iFs sy """this is a test of a reformat for a triple quoted string will it reformat to less than 70 characters for me?"""sm# this is a test of a reformat for a triple quoted string will it reformat to less than 70 characters for me?Rso# this is a test of a reformat for a triple quoted string will it # reformat to less than 70 characters for me?(RRtreformat_comment(R Rt test_stringtresultR,R ((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyttest_reformat_comment¼s  (RRRRA(((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyR=¹stFormatClassTestcBseZd„ZRS(cCsCtjdƒ}|j|jdƒ|jƒ|j|jdƒdS(Nteditor(RRRteditwintclosetNone(R tinstance((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyttest_init_closeÔs (RRRH(((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyRBÓst TextWrappercBs,eZd„Zd„Zd„Zd„ZRS(cCstd|ƒ|_dS(Ntmaster(RR(R RJ((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyt__init__çscCst|j|ƒS(N(tgetattrR(R tname((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyt __getattr__éscCsdS(N((R ((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pytundo_block_startëRcCsdS(N((R ((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pytundo_block_stopìR(RRRKRNRORP(((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyRIæs   tEditorcBseZd„ZejjZRS(cCst|ƒ|_dS(N(RIR(R troot((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyRKïs(RRRKRtget_selection_indicestim_func(((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyRQîs tFormatEventTestcBsbeZdZdZdZdZed„ƒZed„ƒZd„Z d„Z d„Z d „Z RS( s­Test the formatting of text inside a Text widget. This is done with FormatParagraph.format.paragraph_event, which calls functions in the module as appropriate. sv '''this is a test of a reformat for a triple quoted string will it reformat to less than 70 characters for me?''' s '''The first line is under the max width. The second line's length is way over the max width. It goes on and on until it is over 100 characters long. Same thing with the third line. It is also way over the max width, but FormatParagraph will fix it. ''' s,# The first line is under the max width. # The second line's length is way over the max width. It goes on and on until it is over 100 characters long. # Same thing with the third line. It is also way over the max width, but FormatParagraph will fix it. # The fourth line is short like the first line.cCsPtdƒtƒ|_td|jƒ}|jj|_tj|ƒj|_dS(NtguiRR( RRRRRQRRRtformat_paragraph_eventt formatter(RRC((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyR s   cCs#|`|`|jjƒ|`dS(N(RRXRRtdestroy(R((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyt tearDownClasss  cCsV|jjddƒ|jdƒ|j|jjddƒdƒ|jjddƒdS(Ns1.0s Short line tDummyR#R"(RR#RXRtgetR)(R ((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyttest_short_lines cCsì|j}|jd|jƒ|jddƒ|jdddƒ|jddƒ}d}|j||ƒ|jddƒ|jd|jƒ|jdd d ƒ|jdddƒ|jddƒ}d }|j||ƒ|jddƒdS( Ns1.0R#tParameterDoesNothingtlimitiFsz '''this is a test of a reformat for a triple quoted string will it reformat to less than 70 characters for me?''' R"tsels1.11s1.endsv '''this is a test of a reformat for a triple quoted string will it reformat to less than 70 characters for me?'''( RR#R?tmark_setRXR\RR)ttag_add(R RR@R,((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyttest_long_line!s cCs~|j}|jd|jƒ|jdddƒ|jdddƒ|jddƒ}d }|j||ƒ|jdd ƒdS( Ns1.0R`s2.0s4.0R^R_iFR#sà The second line's length is way over the max width. It goes on and on until it is over 100 characters long. Same thing with the third line. It is also way over the max width, but FormatParagraph will fix it. R"(RR#tmultiline_test_stringRbRXR\RR)(R RR@R,((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyttest_multiple_lines<s cCsÜ|j}|jd|jƒ|jdddƒ|jddƒ}d}|j||ƒ|jddƒ|jd|jƒ|jdd d ƒ|jdddƒ|jddƒ}d }|j||ƒ|jddƒdS( Ns1.0R^R_iFR#s/# The first line is under the max width. The second line's length is # way over the max width. It goes on and on until it is over 100 # characters long. Same thing with the third line. It is also way over # the max width, but FormatParagraph will fix it. The fourth line is # short like the first line. R"R`s2.0s3.0s™# The first line is under the max width. # The second line's length is way over the max width. It goes on and # on until it is over 100 characters long. (RR#tmultiline_test_commentRXR\RR)Rb(R RR@R,((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyttest_comment_blockKs ( RRRR?RdRfR6R RZR]RcReRg(((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyRUós    t__main__t verbosityitexit(((tunittesttidlelibRRtidlelib.EditorWindowRtTkinterRRttest.test_supportRtTestCaseRRR7R=RBRIRQRURtmain(((sK/opt/alt/python27/lib64/python2.7/idlelib/idle_test/test_formatparagraph.pyts w„