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

Method test_mac_ver_with_fork

Lib/test/test_platform.py:470–483  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

468 @warnings_helper.ignore_fork_in_thread_deprecation_warnings()
469 @unittest.skipUnless(sys.platform == 'darwin', "OSX only test")
470 def test_mac_ver_with_fork(self):
471 # Issue7895: platform.mac_ver() crashes when using fork without exec
472 #
473 # This test checks that the fix for that issue works.
474 #
475 pid = os.fork()
476 if pid == 0:
477 # child
478 info = platform.mac_ver()
479 os._exit(0)
480
481 else:
482 # parent
483 support.wait_process(pid, exitcode=0)
484
485 def test_ios_ver(self):
486 result = platform.ios_ver()

Callers

nothing calls this directly

Calls 1

_exitMethod · 0.45

Tested by

no test coverage detected