mirror of
https://github.com/python/cpython.git
synced 2025-08-31 05:58:33 +00:00
gh-92913: Clarify changes to PyInitConfig.module_search_paths[_set] fields (GH-92980)
This commit is contained in:
parent
3fd8610002
commit
403d16fa28
5 changed files with 39 additions and 8 deletions
|
@ -236,10 +236,11 @@ class SetConfigTests(unittest.TestCase):
|
|||
module_search_paths=['a', 'b', 'c'])
|
||||
self.assertEqual(sys.path, ['a', 'b', 'c'])
|
||||
|
||||
# Leave sys.path unchanged if module_search_paths_set=0
|
||||
# sys.path is reset if module_search_paths_set=0
|
||||
self.set_config(module_search_paths_set=0,
|
||||
module_search_paths=['new_path'])
|
||||
self.assertEqual(sys.path, ['a', 'b', 'c'])
|
||||
self.assertNotEqual(sys.path, ['a', 'b', 'c'])
|
||||
self.assertNotEqual(sys.path, ['new_path'])
|
||||
|
||||
def test_argv(self):
|
||||
self.set_config(parse_argv=0,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue