| Server IP : 121.121.20.254 / Your IP : 216.73.216.145 Web Server : Microsoft-IIS/10.0 System : Windows NT WEB-SERVER 10.0 build 20348 (Windows Server 2022) AMD64 User : IUSR ( 0) PHP Version : 8.3.28 Disable Function : NONE MySQL : ON | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : C:/Python315/Lib/idlelib/idle_test/__pycache__/ |
Upload File : |
R
>lqj[ c � � Q s ] PHsQQ ksP! )z"Utilities for testing with Tkinterc � ` � U 1Q koU! )a� Decorator for running a test method with a real Tk mainloop.
This starts a Tk mainloop before running the test, and stops it
at the end. This is faster and more robust than the common
alternative method of calling .update() and/or .update_idletasks().
Test methods using this must be written as generator functions,
using "yield" to allow the mainloop to process events and "after"
callbacks, and then continue the test from that point.
The delay argument is passed into root.after(...) calls as the number
of ms to wait before passing execution back to the generator function.
This also assumes that the test class has a .root attribute,
which is a tkinter.Tk object.
For example (from test_sidebar.py):
@run_test_with_tk_mainloop()
def test_single_empty_input(self):
self.do_input('
')
yield
self.assert_sidebar_lines_end_with(['>>>', '>>>'])
c �L :` � [ O R 2 UU 1Q k2 oU! )c � :````� R U 2 nU O nPnUUUUU1Q knRO ] RO R2 RO 2 R% c RgP! )Nc �� :� [ R2 RO RRO R2 P! [ c RO 2 P! [
c o S nRO 2 Po = P! Po = hh 9 h)N)�next�after�
after_idle�
StopIteration�quit� Exception)�exc�after_callback�delay� exception�root�test_generators ������<C:\Python315\\Lib\idlelib\idle_test\tkinter_testing_utils.pyr �Vrun_in_tk_mainloop.<locals>.decorator.<locals>.new_test_method.<locals>.after_callback'