This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author terry.reedy
Recipients JayKrish, Todd.Rovito, ezio.melotti, philwebster, python-dev, terry.reedy
Date 2013-08-19.01:17:47
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1376875069.47.0.809001280605.issue18592@psf.upfronthosting.co.za>
In-reply-to
Content
A subtle point about coverage. The target module must be imported.
from idlelib import SearchDialogBase as sdb  # works.
import idlelib.SearchDialogBase as sdb  # does not
at least not as I invoke coveragepy in my batch file.

With this change, the four uncovered lines were "btn.select()" after 
  if self.engine.is/re/case/word/back/():
in create_option_buttons and create_other_buttons. I added a parameter to checkboxtests and a new method test_create_option_buttons_flipped. That leaves the line after isback() and I think the radiobutton test probably covers that anyway.

The attached file has a few other cosmetic changes, like 'self.searchengine' to 'self.engine'.

I would like to remove the duplicate testing in test_create_widgets. All we care for that test is that create_widgets calls the other four create methods. This could be done either by mocking the other methods (unittest.mock or custom replacement) or by looking to see that there is one entry, option button, other button, and command button.

Were you planning to do the check-label todos?
History
Date User Action Args
2013-08-19 01:17:49terry.reedysetrecipients: + terry.reedy, ezio.melotti, Todd.Rovito, python-dev, JayKrish, philwebster
2013-08-19 01:17:49terry.reedysetmessageid: <1376875069.47.0.809001280605.issue18592@psf.upfronthosting.co.za>
2013-08-19 01:17:49terry.reedylinkissue18592 messages
2013-08-19 01:17:48terry.reedycreate