diff options
author | Alexander Belopolsky <alexander.belopolsky@gmail.com> | 2010-08-16 18:55:46 +0000 |
---|---|---|
committer | Alexander Belopolsky <alexander.belopolsky@gmail.com> | 2010-08-16 18:55:46 +0000 |
commit | 672ec4a5fb55d020b29d1454302baa6a368657d6 (patch) | |
tree | 295113cb0bb58a4ece194fbe5c235fcd6ff530d7 /Lib/test/test_builtin.py | |
parent | a47a98f6e7d964f49c0ffb0c8276e7e61e180cd1 (diff) | |
download | cpython-672ec4a5fb55d020b29d1454302baa6a368657d6.tar.gz |
Issue #665761: functools.reduce() will no longer mask exceptions other
than TypeError raised by the iterator argument. Also added a test to
check that zip() already behaves similarly.
Diffstat (limited to 'Lib/test/test_builtin.py')
-rw-r--r-- | Lib/test/test_builtin.py | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/Lib/test/test_builtin.py b/Lib/test/test_builtin.py index 3f412b7851..b25f3c417d 100644 --- a/Lib/test/test_builtin.py +++ b/Lib/test/test_builtin.py @@ -1234,6 +1234,7 @@ class BuiltinTest(unittest.TestCase): class G: pass self.assertRaises(TypeError, zip, a, G()) + self.assertRaises(RuntimeError, zip, a, TestFailingIter()) # Make sure zip doesn't try to allocate a billion elements for the # result list when one of its arguments doesn't say how long it is. |