summaryrefslogtreecommitdiffstats
path: root/Lib/idlelib
diff options
context:
space:
mode:
authorTerry Jan Reedy <tjreedy@udel.edu>2015-05-16 03:55:49 (GMT)
committerTerry Jan Reedy <tjreedy@udel.edu>2015-05-16 03:55:49 (GMT)
commit188c18d48fe28232a972bc4ff7821de164e625bf (patch)
treed540d8e8d19001067c034b33ca916c15f85857eb /Lib/idlelib
parent7fae66ccd7d21bd66694979f2c8c433c0dab2e54 (diff)
parent75fb816c78be5668d5274df9c9a0c26d841339ad (diff)
downloadcpython-188c18d48fe28232a972bc4ff7821de164e625bf.zip
cpython-188c18d48fe28232a972bc4ff7821de164e625bf.tar.gz
cpython-188c18d48fe28232a972bc4ff7821de164e625bf.tar.bz2
Merge 3.4 #23184: idle tests, remove unused names and imports.
Diffstat (limited to 'Lib/idlelib')
-rw-r--r--Lib/idlelib/idle_test/test_autocomplete.py4
-rw-r--r--Lib/idlelib/idle_test/test_formatparagraph.py2
-rw-r--r--Lib/idlelib/idle_test/test_searchdialogbase.py6
-rw-r--r--Lib/idlelib/idle_test/test_searchengine.py2
-rw-r--r--Lib/idlelib/idle_test/test_text.py1
5 files changed, 7 insertions, 8 deletions
diff --git a/Lib/idlelib/idle_test/test_autocomplete.py b/Lib/idlelib/idle_test/test_autocomplete.py
index bcc853c..3a2192e 100644
--- a/Lib/idlelib/idle_test/test_autocomplete.py
+++ b/Lib/idlelib/idle_test/test_autocomplete.py
@@ -1,6 +1,6 @@
import unittest
from test.support import requires
-from tkinter import Tk, Text, TclError
+from tkinter import Tk, Text
import idlelib.AutoComplete as ac
import idlelib.AutoCompleteWindow as acw
@@ -95,8 +95,8 @@ class AutoCompleteTest(unittest.TestCase):
del ev.mc_state
# If autocomplete window is open, complete() method is called
- testwin = self.autocomplete._make_autocomplete_window()
self.text.insert('1.0', 're.')
+ # This must call autocomplete._make_autocomplete_window()
Equal(self.autocomplete.autocomplete_event(ev), 'break')
# If autocomplete window is not active or does not exist,
diff --git a/Lib/idlelib/idle_test/test_formatparagraph.py b/Lib/idlelib/idle_test/test_formatparagraph.py
index 690c936..f6039e6 100644
--- a/Lib/idlelib/idle_test/test_formatparagraph.py
+++ b/Lib/idlelib/idle_test/test_formatparagraph.py
@@ -2,7 +2,7 @@
import unittest
from idlelib import FormatParagraph as fp
from idlelib.EditorWindow import EditorWindow
-from tkinter import Tk, Text, TclError
+from tkinter import Tk, Text
from test.support import requires
diff --git a/Lib/idlelib/idle_test/test_searchdialogbase.py b/Lib/idlelib/idle_test/test_searchdialogbase.py
index eccdd47..8036b91 100644
--- a/Lib/idlelib/idle_test/test_searchdialogbase.py
+++ b/Lib/idlelib/idle_test/test_searchdialogbase.py
@@ -6,13 +6,13 @@ testing skipping of suite when self.needwrapbutton is false.
'''
import unittest
from test.support import requires
-from tkinter import Tk, Toplevel, Frame, Label, BooleanVar, StringVar
+from tkinter import Tk, Toplevel, Frame ##, BooleanVar, StringVar
from idlelib import SearchEngine as se
from idlelib import SearchDialogBase as sdb
from idlelib.idle_test.mock_idle import Func
-from idlelib.idle_test.mock_tk import Var, Mbox
+## from idlelib.idle_test.mock_tk import Var
-# The following could help make some tests gui-free.
+# The ## imports above & following could help make some tests gui-free.
# However, they currently make radiobutton tests fail.
##def setUpModule():
## # Replace tk objects used to initialize se.SearchEngine.
diff --git a/Lib/idlelib/idle_test/test_searchengine.py b/Lib/idlelib/idle_test/test_searchengine.py
index 2c10461..edbd558 100644
--- a/Lib/idlelib/idle_test/test_searchengine.py
+++ b/Lib/idlelib/idle_test/test_searchengine.py
@@ -7,7 +7,7 @@
import re
import unittest
-from test.support import requires
+# from test.support import requires
from tkinter import BooleanVar, StringVar, TclError # ,Tk, Text
import tkinter.messagebox as tkMessageBox
from idlelib import SearchEngine as se
diff --git a/Lib/idlelib/idle_test/test_text.py b/Lib/idlelib/idle_test/test_text.py
index 5ac2fd7..7e823df 100644
--- a/Lib/idlelib/idle_test/test_text.py
+++ b/Lib/idlelib/idle_test/test_text.py
@@ -3,7 +3,6 @@ import unittest
from test.support import requires
from _tkinter import TclError
-import tkinter as tk
class TextTest(object):