(self)
| 465 | |
| 466 | @unittest.skipIf(mswindows, "pending resolution of issue #15533") |
| 467 | def test_cwd_with_relative_arg(self): |
| 468 | # Check that Popen looks for args[0] relative to cwd if args[0] |
| 469 | # is relative. |
| 470 | python_dir, python_base = self._split_python_path() |
| 471 | rel_python = os.path.join(os.curdir, python_base) |
| 472 | with os_helper.temp_cwd() as wrong_dir: |
| 473 | # Before calling with the correct cwd, confirm that the call fails |
| 474 | # without cwd and with the wrong cwd. |
| 475 | self.assertRaises(FileNotFoundError, subprocess.Popen, |
| 476 | [rel_python]) |
| 477 | self.assertRaises(FileNotFoundError, subprocess.Popen, |
| 478 | [rel_python], cwd=wrong_dir) |
| 479 | python_dir = self._normalize_cwd(python_dir) |
| 480 | self._assert_cwd(python_dir, rel_python, cwd=python_dir) |
| 481 | |
| 482 | @unittest.skipIf(mswindows, "pending resolution of issue #15533") |
| 483 | def test_cwd_with_relative_executable(self): |
nothing calls this directly
no test coverage detected