bpo-45059: Add module cleanup to IDLE test_macosx (GH-28102)
https://github.com/python/cpython/commit/22fe0eb13c3441b71b60aaea0e7fe289a29... commit: 22fe0eb13c3441b71b60aaea0e7fe289a29783da branch: main author: Terry Jan Reedy <tjreedy@udel.edu> committer: terryjreedy <tjreedy@udel.edu> date: 2021-08-31T14:59:35-04:00 summary: bpo-45059: Add module cleanup to IDLE test_macosx (GH-28102) files: M Lib/idlelib/idle_test/test_macosx.py diff --git a/Lib/idlelib/idle_test/test_macosx.py b/Lib/idlelib/idle_test/test_macosx.py index 1932477358689..86da8849e5ca0 100644 --- a/Lib/idlelib/idle_test/test_macosx.py +++ b/Lib/idlelib/idle_test/test_macosx.py @@ -12,6 +12,15 @@ alltypes = mactypes | nontypes +def setUpModule(): + global orig_tktype + orig_tktype = macosx._tk_type + + +def tearDownModule(): + macosx._tk_type = orig_tktype + + class InitTktypeTest(unittest.TestCase): "Test _init_tk_type."
participants (1)
-
terryjreedy