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

@ -27,9 +27,8 @@ class TupleTest(seq_tests.CommonTest):
(1, 3, 5, 7, 9))
def test_keyword_args(self):
with self.assertWarns(DeprecationWarning):
self.assertEqual(tuple(sequence=(x for x in range(10) if x % 2)),
(1, 3, 5, 7, 9))
with self.assertRaisesRegex(TypeError, 'keyword argument'):
tuple(sequence=())
def test_truth(self):
super().test_truth()