Patch [ 1586791 ] better error msgs for some TypeErrors

This commit is contained in:
Georg Brandl 2006-11-19 08:48:30 +00:00
parent db4f255c61
commit 283a1353a0
5 changed files with 27 additions and 16 deletions

View file

@ -219,8 +219,8 @@ if have_unicode:
test_exc(unicode('abc %\u3000','raw-unicode-escape'), 1, ValueError,
"unsupported format character '?' (0x3000) at index 5")
test_exc('%d', '1', TypeError, "int argument required")
test_exc('%g', '1', TypeError, "float argument required")
test_exc('%d', '1', TypeError, "int argument required, not str")
test_exc('%g', '1', TypeError, "float argument required, not str")
test_exc('no format', '1', TypeError,
"not all arguments converted during string formatting")
test_exc('no format', u'1', TypeError,