mirror of
https://github.com/python/cpython.git
synced 2025-11-01 06:01:29 +00:00
bpo-45979: Fix Tkinter tests with old Tk (>= 8.5.12) (GH-31938)
This commit is contained in:
parent
81b425d4dc
commit
dbbe4d2d00
2 changed files with 5 additions and 3 deletions
|
|
@ -4,7 +4,7 @@
|
|||
from tkinter import ttk
|
||||
from test import support
|
||||
from test.support import requires
|
||||
from tkinter.test.support import AbstractTkTest
|
||||
from tkinter.test.support import AbstractTkTest, get_tk_patchlevel
|
||||
|
||||
requires('gui')
|
||||
|
||||
|
|
@ -170,6 +170,8 @@ def test_map_custom_copy(self):
|
|||
newname = f'C.{name}'
|
||||
self.assertEqual(style.map(newname), {})
|
||||
style.map(newname, **default)
|
||||
if theme == 'alt' and name == '.' and get_tk_patchlevel() < (8, 6, 1):
|
||||
default['embossed'] = [('disabled', '1')]
|
||||
self.assertEqual(style.map(newname), default)
|
||||
for key, value in default.items():
|
||||
self.assertEqual(style.map(newname, key), value)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue