Repository navigation
bpo-31904 : skip test_cmd_line case for VxWorks doesn't support preexec #12648
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 1 commit
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
e64be8c
bpo-31904: skip some test case in test_cmd_line for VxWorks doesn't
LihuaZhao 3762b12
add news file
LihuaZhao 48839c2
Move NEWS.d file to test directory
LihuaZhao 700aca1
rework test_cmd_line based on reviewer's comment to use variable inst…
LihuaZhao d3c2377
update test_cmd_line.py to check vxworks platform directly
LihuaZhao 9195390
recover blank line and delete NEWS
LihuaZhao File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next
Next commit
bpo-31904: skip some test case in test_cmd_line for VxWorks doesn't
support preexec subprocess.Popen doesn't support preexec, test_cmd_line need to skip the case which use preexec
- Loading branch information
commit e64be8ccde9e140cfdfff5a976e5872b965e5afc
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -18,6 +18,11 @@ | |
| # Debug build? | ||
| Py_DEBUG = hasattr(sys, "gettotalrefcount") | ||
|
|
||
| def _supports_preexec(): | ||
| if sys.platform == "vxworks": | ||
| return False | ||
| else: | ||
| return True | ||
|
|
||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe 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): | ||
|
|
@@ -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 | ||
|
|
||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
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")