mirror of
https://github.com/python/cpython.git
synced 2025-08-03 16:39:00 +00:00
test_debug in test_tkinter/test_text no longer fails when wantobjects is false.
This commit is contained in:
parent
cc4290bf91
commit
a1de906330
1 changed files with 3 additions and 2 deletions
|
@ -16,12 +16,13 @@ class TextTest(unittest.TestCase):
|
|||
|
||||
def test_debug(self):
|
||||
text = self.text
|
||||
wantobjects = self.root.wantobjects()
|
||||
olddebug = text.debug()
|
||||
try:
|
||||
text.debug(0)
|
||||
self.assertEqual(text.debug(), 0)
|
||||
self.assertEqual(text.debug(), 0 if wantobjects else '0')
|
||||
text.debug(1)
|
||||
self.assertEqual(text.debug(), 1)
|
||||
self.assertEqual(text.debug(), 1 if wantobjects else '1')
|
||||
finally:
|
||||
text.debug(olddebug)
|
||||
self.assertEqual(text.debug(), olddebug)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue