Skip to content
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions Lib/test/test_cmd_line.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,11 @@
# Debug build?
Py_DEBUG = hasattr(sys, "gettotalrefcount")

def _supports_preexec():
if sys.platform == "vxworks":
return False
else:
return True

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suggest:

SUBPROCESS_SUPPORTS_PREEXEC = (sys.platform != "vxworks")


Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hum, please revert this unrelated change.

# XXX (ncoghlan): Move to script_helper and make consistent with run_python
def _kill_python_and_exit_code(p):
Expand Down Expand Up @@ -369,6 +374,7 @@ def test_closed_stdout(self):
# Issue #7111: Python should work without standard streams

@unittest.skipIf(os.name != 'posix', "test needs POSIX semantics")
@unittest.skipUnless(_supports_preexec(), "test needs preexec support in subprocess.Popen")
def _test_no_stdio(self, streams):
code = """if 1:
import os, sys
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Skip test case in test_cmd_line for VxWorks doesn't support preexec when do Popen

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Honestly, I'm not sure that it's worth it to document invidivual tests changes. Can you please remove the NEWS entry? I will simply add the GitHub label "skip news".