@@ -499,8 +499,9 @@ def test_splitlist(self):
499499 (1 , '2' , (3.4 ,)) if self .wantobjects else
500500 ('1' , '2' , '3.4' )),
501501 ]
502+ tk_patchlevel = get_tk_patchlevel ()
502503 if tcl_version >= (8 , 5 ):
503- if not self .wantobjects or get_tk_patchlevel () < (8 , 5 , 5 ):
504+ if not self .wantobjects or tk_patchlevel < (8 , 5 , 5 ):
504505 # Before 8.5.5 dicts were converted to lists through string
505506 expected = ('12' , '\u20ac ' , '\xe2 \x82 \xac ' , '3.4' )
506507 else :
@@ -509,8 +510,11 @@ def test_splitlist(self):
509510 (call ('dict' , 'create' , 12 , '\u20ac ' , b'\xe2 \x82 \xac ' , (3.4 ,)),
510511 expected ),
511512 ]
513+ dbg_info = ('want objects? %s, Tcl version: %s, Tk patchlevel: %s'
514+ % (self .wantobjects , tcl_version , tk_patchlevel ))
512515 for arg , res in testcases :
513- self .assertEqual (splitlist (arg ), res , msg = arg )
516+ self .assertEqual (splitlist (arg ), res ,
517+ 'arg=%a, %s' % (arg , dbg_info ))
514518 self .assertRaises (TclError , splitlist , '{' )
515519
516520 def test_split (self ):
0 commit comments