MCPcopy Index your code
hub / github.com/python/cpython / test_error_iter

Method test_error_iter

Lib/test/test_iter.py:1143–1146  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1141 check_free_after_iterating(self, iter, SequenceClass, (0,))
1142
1143 def test_error_iter(self):
1144 for typ in (DefaultIterClass, NoIterClass):
1145 self.assertRaises(TypeError, iter, typ())
1146 self.assertRaises(ZeroDivisionError, iter, BadIterableClass())
1147
1148 def test_exception_locations(self):
1149 # The location of an exception raised from __init__ or

Callers

nothing calls this directly

Calls 2

assertRaisesMethod · 0.95
BadIterableClassClass · 0.85

Tested by

no test coverage detected