cpython/Lib/test/test_tkinter
Matthias Kievernagel f8ce51a522
gh-47655: Add support for user data and detail of Tk events to tkinter (GH-7142)
Expose the %d substitution as the tkinter.Event attributes:

* "detail" for Enter, Leave, FocusIn, FocusOut, and ConfigureRequest events
* "user_data" for virtual events

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2026-02-25 10:34:00 +02:00
..
__init__.py gh-65784: Add support for parametrized resource wantobjects in regrtests (GH-143570) 2026-01-16 18:38:38 +02:00
__main__.py
README
support.py gh-65784: Add support for parametrized resource wantobjects in regrtests (GH-143570) 2026-01-16 18:38:38 +02:00
test_colorchooser.py gh-65784: Add support for parametrized resource wantobjects in regrtests (GH-143570) 2026-01-16 18:38:38 +02:00
test_font.py gh-65784: Add support for parametrized resource wantobjects in regrtests (GH-143570) 2026-01-16 18:38:38 +02:00
test_geometry_managers.py gh-143754: Add Tkinter methods pack_content(), place_content() and grid_content() (GH-143845) 2026-01-20 09:16:36 +02:00
test_images.py gh-65784: Add support for parametrized resource wantobjects in regrtests (GH-143570) 2026-01-16 18:38:38 +02:00
test_loadtk.py gh-65784: Add support for parametrized resource wantobjects in regrtests (GH-143570) 2026-01-16 18:38:38 +02:00
test_messagebox.py gh-65784: Add support for parametrized resource wantobjects in regrtests (GH-143570) 2026-01-16 18:38:38 +02:00
test_misc.py gh-47655: Add support for user data and detail of Tk events to tkinter (GH-7142) 2026-02-25 10:34:00 +02:00
test_simpledialog.py gh-65784: Add support for parametrized resource wantobjects in regrtests (GH-143570) 2026-01-16 18:38:38 +02:00
test_text.py gh-65784: Add support for parametrized resource wantobjects in regrtests (GH-143570) 2026-01-16 18:38:38 +02:00
test_variables.py gh-65784: Add support for parametrized resource wantobjects in regrtests (GH-143570) 2026-01-16 18:38:38 +02:00
test_widgets.py gh-65784: Add support for parametrized resource wantobjects in regrtests (GH-143570) 2026-01-16 18:38:38 +02:00
widget_tests.py gh-124111: test macOS CI with Tk 9 (#137424) 2025-10-14 00:00:58 -04:00

Writing new tests
=================

Precaution
----------

    New tests should always use only one Tk window at once, like all the
    current tests do. This means that you have to destroy the current window
    before creating another one, and clean up after the test. The motivation
    behind this is that some tests may depend on having its window focused
    while it is running to work properly, and it may be hard to force focus
    on your window across platforms (right now only test_traversal at
    test_ttk.test_widgets.NotebookTest depends on this).