(self)
| 134 | self._check_output_of_default_create() |
| 135 | |
| 136 | def _check_output_of_default_create(self): |
| 137 | self.isdir(self.bindir) |
| 138 | self.isdir(self.include) |
| 139 | self.isdir(*self.lib) |
| 140 | p = self.get_env_file('lib64') |
| 141 | if os.path.exists(p): |
| 142 | self.assertFalse(os.path.islink(p)) |
| 143 | data = self.get_text_file_contents('pyvenv.cfg') |
| 144 | executable = sys._base_executable |
| 145 | path = os.path.dirname(executable) |
| 146 | self.assertIn('home = %s' % path, data) |
| 147 | self.assertIn('executable = %s' % |
| 148 | os.path.realpath(sys.executable), data) |
| 149 | copies = '' if os.name=='nt' else ' --copies' |
| 150 | cmd = (f'command = {sys.executable} -m venv{copies} --without-pip ' |
| 151 | f'--without-scm-ignore-files {self.env_dir}') |
| 152 | self.assertIn(cmd, data) |
| 153 | fn = self.get_env_file(self.bindir, self.exe) |
| 154 | if not os.path.exists(fn): # diagnostics for Windows buildbot failures |
| 155 | bd = self.get_env_file(self.bindir) |
| 156 | print('Contents of %r:' % bd) |
| 157 | print(' %r' % os.listdir(bd)) |
| 158 | self.assertTrue(os.path.exists(fn), 'File %r should exist.' % fn) |
| 159 | |
| 160 | def test_config_file_command_key(self): |
| 161 | options = [ |
no test coverage detected