mirror of
https://github.com/python/cpython.git
synced 2025-07-23 11:15:24 +00:00
gh-98790: When DLLs directory is missing on Windows, assume executable_dir contains PYD files instead (GH-98936)
This commit is contained in:
parent
dc4bf6b229
commit
3ff659aea2
4 changed files with 53 additions and 20 deletions
|
@ -239,6 +239,29 @@ class MockGetPathTests(unittest.TestCase):
|
|||
actual = getpath(ns, expected)
|
||||
self.assertEqual(expected, actual)
|
||||
|
||||
def test_no_dlls_win32(self):
|
||||
"Test a layout on Windows with no DLLs directory."
|
||||
ns = MockNTNamespace(
|
||||
argv0=r"C:\Python\python.exe",
|
||||
real_executable=r"C:\Python\python.exe",
|
||||
)
|
||||
ns.add_known_xfile(r"C:\Python\python.exe")
|
||||
ns.add_known_file(r"C:\Python\Lib\os.py")
|
||||
expected = dict(
|
||||
executable=r"C:\Python\python.exe",
|
||||
base_executable=r"C:\Python\python.exe",
|
||||
prefix=r"C:\Python",
|
||||
exec_prefix=r"C:\Python",
|
||||
module_search_paths_set=1,
|
||||
module_search_paths=[
|
||||
r"C:\Python\python98.zip",
|
||||
r"C:\Python\Lib",
|
||||
r"C:\Python",
|
||||
],
|
||||
)
|
||||
actual = getpath(ns, expected)
|
||||
self.assertEqual(expected, actual)
|
||||
|
||||
def test_normal_posix(self):
|
||||
"Test a 'standard' install layout on *nix"
|
||||
ns = MockPosixNamespace(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue