[Python-checkins] cpython (2.7): Issue #18365: 2.7 corrections so tests run
terry.reedy
python-checkins at python.org
Sat Jul 13 06:02:46 CEST 2013
http://hg.python.org/cpython/rev/008d83c4efaf
changeset: 84611:008d83c4efaf
branch: 2.7
user: Terry Jan Reedy <tjreedy at udel.edu>
date: Sat Jul 13 00:02:27 2013 -0400
summary:
Issue #18365: 2.7 corrections so tests run
files:
Lib/idlelib/idle_test/mock_tk.py | 2 +-
Lib/idlelib/idle_test/test_text.py | 6 +++---
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/Lib/idlelib/idle_test/mock_tk.py b/Lib/idlelib/idle_test/mock_tk.py
--- a/Lib/idlelib/idle_test/mock_tk.py
+++ b/Lib/idlelib/idle_test/mock_tk.py
@@ -114,7 +114,7 @@
try:
index=index.lower()
except AttributeError:
- raise TclError('bad text index "%s"' % index) from None
+ raise TclError('bad text index "%s"' % index)
lastline = len(self.data) - 1 # same as number of text lines
if index == 'insert':
diff --git a/Lib/idlelib/idle_test/test_text.py b/Lib/idlelib/idle_test/test_text.py
--- a/Lib/idlelib/idle_test/test_text.py
+++ b/Lib/idlelib/idle_test/test_text.py
@@ -1,9 +1,9 @@
# Test mock_tk.Text class against tkinter.Text class by running same tests with both.
import unittest
-from test.support import requires
+from test.test_support import requires
from _tkinter import TclError
-import tkinter as tk
+import Tkinter as tk
class TextTest(object):
@@ -214,7 +214,7 @@
@classmethod
def setUpClass(cls):
requires('gui')
- from tkinter import Tk, Text
+ from Tkinter import Tk, Text
cls.Text = Text
cls.root = Tk()
--
Repository URL: http://hg.python.org/cpython
More information about the Python-checkins
mailing list