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

Method test_custom_platlibdir_posix

Lib/test/test_getpath.py:535–558  ·  view source on GitHub ↗

Test an install with custom platlibdir on *nix

(self)

Source from the content-addressed store, hash-verified

533 self.assertEqual(expected, actual)
534
535 def test_custom_platlibdir_posix(self):
536 "Test an install with custom platlibdir on *nix"
537 ns = MockPosixNamespace(
538 PREFIX="/usr",
539 argv0="/linkfrom/python",
540 PLATLIBDIR="lib64",
541 )
542 ns.add_known_xfile("/usr/bin/python")
543 ns.add_known_file("/usr/lib64/python9.8/os.py")
544 ns.add_known_dir("/usr/lib64/python9.8/lib-dynload")
545 expected = dict(
546 executable="/linkfrom/python",
547 base_executable="/linkfrom/python",
548 prefix="/usr",
549 exec_prefix="/usr",
550 module_search_paths_set=1,
551 module_search_paths=[
552 "/usr/lib64/python98.zip",
553 "/usr/lib64/python9.8",
554 "/usr/lib64/python9.8/lib-dynload",
555 ],
556 )
557 actual = getpath(ns, expected)
558 self.assertEqual(expected, actual)
559
560 def test_framework_macos(self):
561 """ Test framework layout on macOS

Callers

nothing calls this directly

Calls 6

add_known_xfileMethod · 0.95
add_known_fileMethod · 0.95
add_known_dirMethod · 0.95
MockPosixNamespaceClass · 0.85
getpathFunction · 0.85
assertEqualMethod · 0.45

Tested by

no test coverage detected