bpo-29695: Remove bad keyword parameters in int(), bool(), float(), list() and tuple(). (#518)

This commit is contained in:
Serhiy Storchaka 2017-03-06 17:01:06 +02:00 committed by GitHub
parent b76ad5121e
commit 2e5642422f
12 changed files with 31 additions and 61 deletions

View file

@ -209,8 +209,8 @@ class GeneralFloatCases(unittest.TestCase):
self.assertIs(type(FloatSubclass(F())), FloatSubclass)
def test_keyword_args(self):
with self.assertWarns(DeprecationWarning):
self.assertEqual(float(x='3.14'), 3.14)
with self.assertRaisesRegex(TypeError, 'keyword argument'):
float(x='3.14')
def test_is_integer(self):
self.assertFalse((1.1).is_integer())