def test_catches_handled_errors(self):
        try:
            with self.breaker:
                raise IOError("error")
        except __HOLE__:
            self.assertEquals(len(self.breaker.errors), 1)
        else:
            self.assertTrue(False, "exception not raised")
dataset/ETHPy150Open edgeware/python-circuit/circuit/test/test_breaker.py/CircuitBreakerTestCase.test_catches_handled_errors