mirror of
https://github.com/python/cpython.git
synced 2025-08-24 10:45:53 +00:00
bpo-30534: Fixed error messages when pass keyword arguments (#1901)
to functions implemented in C that don't support this. Also unified error messages for functions that don't take positional or keyword arguments.
This commit is contained in:
parent
5cefb6cfdd
commit
5eb788bf7f
5 changed files with 116 additions and 45 deletions
|
@ -1996,7 +1996,7 @@ class SubclassWithKwargsTest(unittest.TestCase):
|
|||
Subclass(newarg=1)
|
||||
except TypeError as err:
|
||||
# we expect type errors because of wrong argument count
|
||||
self.assertNotIn("does not take keyword arguments", err.args[0])
|
||||
self.assertNotIn("keyword arguments", err.args[0])
|
||||
|
||||
@support.cpython_only
|
||||
class SizeofTest(unittest.TestCase):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue