diff options
| author | Victor Stinner <vstinner@python.org> | 2022-12-05 13:23:35 (GMT) |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-12-05 13:23:35 (GMT) |
| commit | 038b151963d9d4a5f4c852544fb5b0402ffcb218 (patch) | |
| tree | 41f8bd853d3e6018853eb9c117d5568b47cfa148 /Lib/test/test_cmd_line_script.py | |
| parent | e3a3863cb9561705d3dd59a9367427ed45dfb5ea (diff) | |
| download | cpython-038b151963d9d4a5f4c852544fb5b0402ffcb218.zip cpython-038b151963d9d4a5f4c852544fb5b0402ffcb218.tar.gz cpython-038b151963d9d4a5f4c852544fb5b0402ffcb218.tar.bz2 | |
gh-100005: Skip test_script_as_dev_fd() on FreeBSD (#100006)
On FreeBSD, skip test_script_as_dev_fd() of test_cmd_line_script if
fdescfs is not mounted (at /dev/fd).
Diffstat (limited to 'Lib/test/test_cmd_line_script.py')
| -rw-r--r-- | Lib/test/test_cmd_line_script.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Lib/test/test_cmd_line_script.py b/Lib/test/test_cmd_line_script.py index c838e95..f10d72e 100644 --- a/Lib/test/test_cmd_line_script.py +++ b/Lib/test/test_cmd_line_script.py @@ -753,6 +753,9 @@ class CmdLineTest(unittest.TestCase): self.assertNotEqual(proc.returncode, 0) @unittest.skipUnless(os.path.exists('/dev/fd/0'), 'requires /dev/fd platform') + @unittest.skipIf(sys.platform.startswith("freebsd") and + os.stat("/dev").st_dev == os.stat("/dev/fd").st_dev, + "Requires fdescfs mounted on /dev/fd on FreeBSD") def test_script_as_dev_fd(self): # GH-87235: On macOS passing a non-trivial script to /dev/fd/N can cause # problems because all open /dev/fd/N file descriptors share the same |
