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

Method test_raise_exception

Lib/test/test_faulthandler.py:853–865  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

851
852 @unittest.skipUnless(MS_WINDOWS, 'specific to Windows')
853 def test_raise_exception(self):
854 for exc, name in (
855 ('EXCEPTION_ACCESS_VIOLATION', 'access violation'),
856 ('EXCEPTION_INT_DIVIDE_BY_ZERO', 'int divide by zero'),
857 ('EXCEPTION_STACK_OVERFLOW', 'stack overflow'),
858 ):
859 self.check_windows_exception(f"""
860 import faulthandler
861 faulthandler.enable()
862 faulthandler._raise_exception(faulthandler._{exc})
863 """,
864 3,
865 name)
866
867 @unittest.skipUnless(MS_WINDOWS, 'specific to Windows')
868 def test_ignore_exception(self):

Callers

nothing calls this directly

Calls 1

Tested by

no test coverage detected