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

Method failAsBool

Lib/test/test_with.py:602–604  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

600 self.assertRaises(AssertionError, falseAsBool)
601
602 def failAsBool():
603 with cm(lambda: 1//0):
604 self.fail("Should NOT see this")
605 self.assertRaises(ZeroDivisionError, failAsBool)
606
607

Callers

nothing calls this directly

Calls 2

cmClass · 0.85
failMethod · 0.45

Tested by

no test coverage detected