diff options
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/test/test_enumerate.py | 2 | ||||
-rw-r--r-- | Lib/test/test_generators.py | 2 | ||||
-rw-r--r-- | Lib/test/test_genexps.py | 2 | ||||
-rw-r--r-- | Lib/test/test_reprlib.py (renamed from Lib/test/test_repr.py) | 0 |
4 files changed, 4 insertions, 2 deletions
diff --git a/Lib/test/test_enumerate.py b/Lib/test/test_enumerate.py index 8cebf44..f5c5689 100644 --- a/Lib/test/test_enumerate.py +++ b/Lib/test/test_enumerate.py @@ -138,6 +138,8 @@ class TestReversed(unittest.TestCase): for data in 'abc', range(5), tuple(enumerate('abc')), A(), range(1,17,5): self.assertEqual(list(data)[::-1], list(reversed(data))) self.assertRaises(TypeError, reversed, {}) + # don't allow keyword arguments + self.assertRaises(TypeError, reversed, [], a=1) def test_range_optimization(self): x = range(1) diff --git a/Lib/test/test_generators.py b/Lib/test/test_generators.py index e27eadd..56f23db 100644 --- a/Lib/test/test_generators.py +++ b/Lib/test/test_generators.py @@ -927,7 +927,7 @@ Test the __name__ attribute and the repr() >>> g.__name__ 'f' >>> repr(g) # doctest: +ELLIPSIS -'<f generator object at ...>' +'<generator object f at ...>' """ # conjoin is a simple backtracking generator, named in honor of Icon's diff --git a/Lib/test/test_genexps.py b/Lib/test/test_genexps.py index c8abbcc..593c1c5 100644 --- a/Lib/test/test_genexps.py +++ b/Lib/test/test_genexps.py @@ -92,7 +92,7 @@ Verify that parenthesis are required when used as a keyword argument value Verify that parenthesis are required when used as a keyword argument value >>> dict(a = (i for i in range(10))) #doctest: +ELLIPSIS - {'a': <<genexpr> generator object at ...>} + {'a': <generator object <genexpr> at ...>} Verify early binding for the outermost for-expression diff --git a/Lib/test/test_repr.py b/Lib/test/test_reprlib.py index 442c048..442c048 100644 --- a/Lib/test/test_repr.py +++ b/Lib/test/test_reprlib.py |