New submission from Phil Webster:
Started writing the tests for textView.py.
--
components: IDLE
files: test_textview.patch
keywords: patch
messages: 196820
nosy: JayKrish, Todd.Rovito, philwebster, terry.reedy
priority: normal
severity: normal
status: open
title: IDLE: Unit test for
Phil Webster added the comment:
Added tests for labels, a mock function for widget creation, a back option for
radiobuttontests, and the docstring fixes that Terry mentioned.
--
Added file: http://bugs.python.org/file31542/18592_test_searchdialog2.diff
Phil Webster added the comment:
I've attached my work so far in order to get feedback before I head too far in
the wrong direction. I'm not sure if my addition of mock events and
AutoCompleteWindow is the right way to go and I'm open to any guidance.
--
keywords: +p
New submission from Phil Webster:
If you open a new editor window in IDLE, some modules will autocomplete (re,
os, other common modules used by IDLE) and others will not (textwrap, datetime,
...). The current solution is to run your module or type the imports into the
shell window to get
Phil Webster added the comment:
I've attached a patch that attempts to address the issues above. For the tests,
I made some changes because the cursor doesn't end in exactly the same spot
with line endings.
Here's a quick summary of the changes:
1. Removed format_paragraph and
Phil Webster added the comment:
As suggested by Ezio, I factored out the button tests to a common method.
--
Added file: http://bugs.python.org/file31220/test_searchdialogbase2.patch
___
Python tracker
<http://bugs.python.org/issue18
Phil Webster added the comment:
In the case of no selection would it make sense to only format if the cursor is
in a string/comment? If not in a string or comment, the single line that the
cursor is in could be formatted with a line ending backslash or not at all.
Otherwise Format Paragraph
Changes by Phil Webster :
--
nosy: +philwebster
___
Python tracker
<http://bugs.python.org/issue18583>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Phil Webster :
--
keywords: +patch
Added file: http://bugs.python.org/file31082/test_searchdialogbase.patch
___
Python tracker
<http://bugs.python.org/issue18
New submission from Phil Webster:
This is a basic set of tests for SearchDialogBase. It mainly consists of gui
code, so I was not completely sure of how/what to test. Before venturing any
further, I thought I would make sure I'm heading in the right direction.
--
components:
Phil Webster added the comment:
This patch moves the comment_header code to reformat_comment, adds tests for
reformat_comment, and implements the fix that Todd mentioned in #18429. In
addition, I changed the get_comment_header and get_indent regular expressions
to only look for spaces and
Phil Webster added the comment:
Added tests for the rest of the SearchEngine module. I used the mock
tkMessageBox for testing the error display, but used the tkinter Text widget
for other tests because mark_set and tag_add/remove haven't been added to the
mock yet.
--
Added
Changes by Phil Webster :
--
nosy: +philwebster
___
Python tracker
<http://bugs.python.org/issue18504>
___
___
Python-bugs-list mailing list
Unsubscribe:
Phil Webster added the comment:
I added and rewrote tests to use the Text widget (when necessary). The only
changes made to FormatParagraph are documentation/comment formatting and the if
__main__ function. I will work on the comment header behavior separately and
can post the patch in this
New submission from Phil Webster:
This test uses the mock text widget to search forwards and backwards, with and
without wrapping. It also tests for empty matches with the 'ok' flag set in
search_text(). The patch relies on the mock text tag_add function implemented
Phil Webster added the comment:
After reading Terry's comments on the initial patch I turned FormatParagraph's
initial comments into a docstring and made sure that all lines were < 80
characters.
--
Added file:
http://bugs.python.org/file30960/18226IDLEUnitTestFormatPar
Phil Webster added the comment:
Added tests for FormatParagraph using single/multiline comment blocks and
single/multiline strings in the mock editor window.
Here is a summary of the changes:
FormatParagraph.py
- description for format_paragraph_event
- modified so that selecting a long
Phil Webster added the comment:
Using tk.Text for more involved tests sounds good (at least as a start). The
pass functions were used to get the FormatParagraph test (#18226) working.
I've been using the same effbot.org site as a reference and haven't found
anything mor
Phil Webster added the comment:
Thanks Terry, I will start PEP8-checking my code before I submit (as well as
testing more thoroughly). I was thinking the same thing about the logic behind
_decode and index functions needing to be combined.
How would you recommend adding functionality to the
Changes by Phil Webster :
--
nosy: +philwebster
___
Python tracker
<http://bugs.python.org/issue18425>
___
___
Python-bugs-list mailing list
Unsubscribe:
New submission from Phil Webster:
Continuing the IDLE unittest framework from #15392. Depends on #18365.
--
components: IDLE
messages: 192713
nosy: JayKrish, Todd.Rovito, philwebster, terry.reedy
priority: normal
severity: normal
status: open
title: IDLE Improvements: Unit test for
New submission from Phil Webster:
I've started writing this test which depends on #18365.
--
components: IDLE
messages: 192711
nosy: JayKrish, Todd.Rovito, philwebster, terry.reedy
priority: normal
severity: normal
status: open
title: IDLE Improvements: Unit test for AutoComple
Phil Webster added the comment:
This patch contains mock_idle.py and the rstrip test using the mock text widget
from #18365.
Terry- For some reason, the Text widget always contains a '\n' as the last
character even when there is nothing visible. Doing a text.get('1.0',
Phil Webster added the comment:
I made slight modifications to Todd's initial patch to test the mock Text
widget from #18365.
Thank you for the helpful feedback Terry!
--
Added file:
http://bugs.python.org/file30853/18226IDLEUnitTestFormatParagraph2.
Phil Webster added the comment:
Added Text class to mock_tk.py and GUI/non-GUI tests in test_text.py. Running
the IDLE tests produced no errors for me.
--
keywords: +patch
Added file: http://bugs.python.org/file30851/mock_text.patch
___
Python
Phil Webster added the comment:
Added to Terry's Text Widget code (in #18226) and created mock_idle.py for the
mock EditorWindow. Todd's FormatParagraph test in the aforementioned issue also
passes with the mock EditorWindow.
--
Added file: http://bugs.python.org
Phil Webster added the comment:
I'm not sure if this is worth pursuing, but I made a mock Text Widget that
behaves more like an actual Text Widget. I've attached my modified mock_tk.py
which I used to create a mock editor window. This works for the test I made in
#18279, but I am al
Changes by Phil Webster :
--
nosy: +philwebster
___
Python tracker
<http://bugs.python.org/issue18292>
___
___
Python-bugs-list mailing list
Unsubscribe:
Phil Webster added the comment:
Modified the first patch to get rid of mock EditorWindow in favor of the real
thing. Also renamed the test to 'test_rstrip'.
--
Added file: http://bugs.python.org/file30694/test_rstrip.patch
___
Python trac
Phil Webster added the comment:
Thank you for the feedback Terry. I'm not seeing the traceback without '-ugui'
either, so I'm going to look into that. I get the same results with
requires('gui') moved inside of setUp, is that what you mean by wrapping?
For mock_
Changes by Phil Webster :
--
keywords: +patch
Added file: http://bugs.python.org/file30664/test_rstripext.patch
___
Python tracker
<http://bugs.python.org/issue18
Changes by Phil Webster :
--
nosy: +Todd.Rovito
___
Python tracker
<http://bugs.python.org/issue18279>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Phil Webster :
--
nosy: +terry.reedy
___
Python tracker
<http://bugs.python.org/issue18279>
___
___
Python-bugs-list mailing list
Unsubscribe:
New submission from Phil Webster:
This is a single test for RstripExtension.py, following from #15392. I also
added a mock EditorWindow module with a Text widget for testing.
test_rstripextension.py seems to run fine inside IDLE and produces the
following output:
>>>
test_
Changes by Phil Webster :
--
nosy: +philwebster
___
Python tracker
<http://bugs.python.org/issue18103>
___
___
Python-bugs-list mailing list
Unsubscribe:
Phil Webster added the comment:
I've attached a patch that attempts to get sys.ps1 for the prompt.
Unfortunately it prints out blue because it is treated as output from running
print(sys.ps1) as if the user had typed it in. Now that I have a better
understanding of the issue, I may be ab
Phil Webster added the comment:
After reading about beginners having difficulty with IDLE's terminal behavior,
I wrote a (very) simple patch to disable left clicking in the text area. I
realize that this doesn't solve the problem completely (and the fact that there
is already a
37 matches
Mail list logo