summaryrefslogtreecommitdiffstats
path: root/Lib/test
diff options
context:
space:
mode:
authorZachary Ware <zachary.ware@gmail.com>2015-05-22 16:36:53 (GMT)
committerZachary Ware <zachary.ware@gmail.com>2015-05-22 16:36:53 (GMT)
commit7dc9dea7784c2e8cd07af11d1757ae58a3492bd6 (patch)
tree1721a591d3af3f79043e7a92b5dd0ca55b9c9ce4 /Lib/test
parent3cfec2e2fcab9f39121cec362b78ac235093ca1c (diff)
downloadcpython-7dc9dea7784c2e8cd07af11d1757ae58a3492bd6.zip
cpython-7dc9dea7784c2e8cd07af11d1757ae58a3492bd6.tar.gz
cpython-7dc9dea7784c2e8cd07af11d1757ae58a3492bd6.tar.bz2
Issue #20035: Reimplement tkinter._fix module as a C function.
The new private C function makes no permanent changes to the environment and is #ifdef'd out on non-Windows platforms.
Diffstat (limited to 'Lib/test')
-rw-r--r--Lib/test/test_tcl.py4
-rw-r--r--Lib/test/test_tk.py3
-rw-r--r--Lib/test/test_ttk_guionly.py4
-rw-r--r--Lib/test/test_ttk_textonly.py3
4 files changed, 2 insertions, 12 deletions
diff --git a/Lib/test/test_tcl.py b/Lib/test/test_tcl.py
index b612517..5be645a 100644
--- a/Lib/test/test_tcl.py
+++ b/Lib/test/test_tcl.py
@@ -7,9 +7,7 @@ from test import support
# Skip this test if the _tkinter module wasn't built.
_tkinter = support.import_module('_tkinter')
-# Make sure tkinter._fix runs to set up the environment
-tkinter = support.import_fresh_module('tkinter')
-
+import tkinter
from tkinter import Tcl
from _tkinter import TclError
diff --git a/Lib/test/test_tk.py b/Lib/test/test_tk.py
index 62729f0..48cefd9 100644
--- a/Lib/test/test_tk.py
+++ b/Lib/test/test_tk.py
@@ -2,9 +2,6 @@ from test import support
# Skip test if _tkinter wasn't built.
support.import_module('_tkinter')
-# Make sure tkinter._fix runs to set up the environment
-support.import_fresh_module('tkinter')
-
# Skip test if tk cannot be initialized.
support.requires('gui')
diff --git a/Lib/test/test_ttk_guionly.py b/Lib/test/test_ttk_guionly.py
index fcdedac..490e723 100644
--- a/Lib/test/test_ttk_guionly.py
+++ b/Lib/test/test_ttk_guionly.py
@@ -5,12 +5,10 @@ from test import support
# Skip this test if _tkinter wasn't built.
support.import_module('_tkinter')
-# Make sure tkinter._fix runs to set up the environment
-tkinter = support.import_fresh_module('tkinter')
-
# Skip test if tk cannot be initialized.
support.requires('gui')
+import tkinter
from _tkinter import TclError
from tkinter import ttk
from tkinter.test import runtktests
diff --git a/Lib/test/test_ttk_textonly.py b/Lib/test/test_ttk_textonly.py
index 1cfeb15..566fc9d 100644
--- a/Lib/test/test_ttk_textonly.py
+++ b/Lib/test/test_ttk_textonly.py
@@ -4,9 +4,6 @@ from test import support
# Skip this test if _tkinter does not exist.
support.import_module('_tkinter')
-# Make sure tkinter._fix runs to set up the environment
-support.import_fresh_module('tkinter')
-
from tkinter.test import runtktests
def test_main():