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

Method test_init_setpath_config

Lib/test/test_embed.py:1402–1425  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1400 ignore_stderr=True)
1401
1402 def test_init_setpath_config(self):
1403 # Test Py_SetPath() with PyConfig
1404 config = self._get_expected_config()
1405 paths = config['config']['module_search_paths']
1406
1407 config = {
1408 # set by Py_SetPath()
1409 'module_search_paths': paths,
1410 'prefix': '',
1411 'base_prefix': '',
1412 'exec_prefix': '',
1413 'base_exec_prefix': '',
1414 # The current getpath.c doesn't determine the stdlib dir
1415 # in this case.
1416 'stdlib_dir': '',
1417 'use_frozen_modules': not support.Py_DEBUG,
1418 # overridden by PyConfig
1419 'program_name': 'conf_program_name',
1420 'base_executable': 'conf_executable',
1421 'executable': 'conf_executable',
1422 }
1423 env = {'TESTPATH': os.path.pathsep.join(paths)}
1424 self.check_all_configs("test_init_setpath_config", config,
1425 api=API_PYTHON, env=env, ignore_stderr=True)
1426
1427 def module_search_paths(self, prefix=None, exec_prefix=None):
1428 config = self._get_expected_config()

Callers

nothing calls this directly

Calls 3

_get_expected_configMethod · 0.95
check_all_configsMethod · 0.95
joinMethod · 0.45

Tested by

no test coverage detected