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.

Title: Test that self.bell is called in IDLE classes when intended.
Type: enhancement Stage: needs patch
Components: IDLE, Tests Versions: Python 3.10
Status: open Resolution:
Dependencies: Superseder:
Assigned To: terry.reedy Nosy List: terry.reedy
Priority: normal Keywords:

Created on 2016-08-11 04:04 by terry.reedy, last changed 2022-04-11 14:58 by admin.

Messages (1)
msg272397 - (view) Author: Terry J. Reedy (terry.reedy) * (Python committer) Date: 2016-08-11 04:04
Spinoff of #27732, which changed 5 tested bell-using classes to consistently call 'self.bell()' (instead of self.text.bell or whatever) so tests for such classes could replace the function with a quiet function.  For 4 of the classes, the replacement is currently 'lambda: None'.  For undo, it is a quiet mock that replaced a noisy mock wrapping and calling the original bell().  The purpose of the mock, either way, is to test that bell() is called when intended.

I plan to add a new idle_test.mock_tk.bell function.  I am considering having it automatically reset 'called' when 'called is accessed.  In any case, this issue is about extending the use of mock bells to other tests.
Date User Action Args
2022-04-11 14:58:34adminsetgithub: 71920
2020-06-06 18:19:20terry.reedysetversions: + Python 3.10, - Python 3.6
2016-08-11 04:04:34terry.reedysetcomponents: + Tests
2016-08-11 04:04:12terry.reedycreate