Lines Matching +full:cross +full:- +full:spawn
4 Copyright (C) 2011-2012 Vinay Sajip.
54 print(err.decode('utf-8', 'backslashreplace'))
74 self.exe = os.path.split(executable)[-1]
94 def get_text_file_contents(self, *args, encoding='utf-8'):
140 copies = '' if os.name=='nt' else ' --copies'
141 cmd = f'command = {sys.executable} -m venv{copies} --without-pip {self.env_dir}'
153 ('symlinks', '--copies'),
154 ('with_pip', '--without-pip'),
155 ('system_site_packages', '--system-site-packages'),
156 ('clear', '--clear'),
157 ('upgrade', '--upgrade'),
158 ('upgrade_deps', '--upgrade-deps'),
159 ('prompt', '--prompt'),
173 for opt in ('--system-site-packages', '--clear', '--upgrade',
174 '--upgrade-deps', '--prompt'):
226 '-m',
229 '--upgrade',
248 cmd = [envpy, '-c', None]
266 cmd = [envpy, '-c', None]
289 cmd = [envpy, '-c', None]
308 ('Lib', 'site-packages'),
316 ('lib', 'python%d.%d' % sys.version_info[:2], 'site-packages'),
389 Test isolation from system site-packages
395 self.assertIn('include-system-site-packages = %s\n' % s, data)
420 # to the source build - so Python can't initialise properly.
430 out, err = check_output([envpy, '-c',
444 out, err = check_output([envpy, '-c',
448 # gh-124651: test quoted strings
466 'python -c \'import sys; print(sys.executable)\'\n'
467 'python -c \'import os; print(os.environ["VIRTUAL_ENV"])\'\n'
474 # gh-124651: test quoted strings
492 'python -c \'import sys; print(sys.executable)\'\n'
493 'python -c \'import os; print(os.environ["VIRTUAL_ENV"])\'\n'
500 # gh-124651: test quoted strings on Windows
516 f'{self.exe} -c "import sys; print(sys.executable)" & '
517 f'{self.exe} -c "import os; print(os.environ[\'VIRTUAL_ENV\'])" & '
536 [activate, '&', self.exe, '-c', 'print(0)'],
544 Test that the multiprocessing is able to spawn.
546 # bpo-36342: Instantiation of a Pool object imports the
555 out, err = check_output([envpy, '-c',
565 Test that the multiprocessing is able to spawn itself
587 f.write("set -euo pipefail\n"
603 out, err = check_output([envpy, '-c',
621 Test that when create venv from non-installed python, the zip path
625 # First try to create a non-installed python. It's not a real full
626 # functional non-installed python, but enough for this test.
641 # Copy stdlib files to the non-installed python so venv can
651 if name == "site-packages":
662 "-m",
664 "--without-pip",
666 # Our fake non-installed python is not fully functional because
672 # LD_LIBRARY_PATH so the non-installed python can find and link
685 # Now check the venv created from the non-installed python has
687 cmd = [envpy, '-S', '-c', 'import sys; print(sys.path)']
697 out, err = check_output([envpy, '-c',
701 err = err.decode("latin-1") # Force to text, prevent decoding errors
703 out = out.decode("latin-1") # Force to text, prevent decoding errors
730 # pip's cross-version compatibility may trigger deprecation
744 bad_config = "[global]\nno-install=1"
746 # cross-platform variation in test code behaviour
766 out, err = check_output([envpy, '-W', 'ignore::DeprecationWarning',
767 '-W', 'ignore::ImportWarning', '-I',
768 '-m', 'pip', '--version'])
771 err = err.decode("latin-1") # Force to text, prevent decoding errors
773 out = out.decode("latin-1") # Force to text, prevent decoding errors
776 env_dir = os.fsencode(self.env_dir).decode("latin-1")
788 '-W', 'ignore::DeprecationWarning',
789 '-W', 'ignore::ImportWarning', '-I',
790 '-m', 'ensurepip._uninstall'])
793 err = err.decode("latin-1") # Force to text, prevent decoding errors
798 # executing pip with sudo, you may want sudo's -H flag."
807 out = out.decode("latin-1") # Force to text, prevent decoding errors
812 # other case, pip may still be available in the system site-packages