Repository navigation
tests: re-harden test_remote_usage_prog (replaces #507) - #1396
Open
RonnyPfannschmidt wants to merge 3 commits into
Open
RonnyPfannschmidt wants to merge 3 commits into
RonnyPfannschmidt wants to merge 3 commits into
Conversation
The meaning of the test is to check that "prog" is not "-c", which was weakened in 93780dc.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_012f14GcdYkiWd68e7zAvLhN
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_012f14GcdYkiWd68e7zAvLhN
RonnyPfannschmidt
requested review from
nicoddemus
and
a balanced review from Copilot
October 8, 2026 16:28
There was a problem hiding this comment.
🟢 Approval recommended
The focused test-only change correctly enforces the intended worker program name.
0 open findings
What changed in this PR
Strengthens the remote usage test to prevent regression to a worker program name of -c.
Changes:
- Validates
UsageErroroutput againstpytest.pyor__main__.py. - Adds a changelog entry crediting the original contribution.
| File | Description |
|---|---|
testing/test_remote.py |
Tightens worker usage-output assertions. |
changelog/1396.trivial.rst |
Documents the test hardening. |
🧠 Review effort: Balanced
Give feedback about Copilot approvals in this survey to enter a drawing for a $150 gift card.
This branch has not been deployed
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Requested by Ronny · project thread
🤖 Written by Claude Opus 5.5 via Claude Code for the pytest-xdist maintainers; I prompted it, it did the work, I read it.
This replaces #507 by @blueyed. It keeps his original commit and adds a merge of current
masteron top of it. That PR's branch lives on a fork that we couldn't push the merge to.Before:
test_remote_usage_progonly checks for*usage: *and*error: my_usage_error. It would still pass if the worker's argparseprogwere-c, which was the regression the test was meant to catch. The check was weakened in 93780dc.After: the test matches the
UsageErrorlines and requiresprogto bepytest.pyor__main__.py.How: blueyed's
re_match_linesassertion, merged into the current pytester-based version of the test (pytest 9optparsersplit). The merge resolution only keeps the new assertion, alongside thetest_remote_sys_pathtest that was added since. It passes locally on Python 3.13 with the pytest pinned by the repo.changelog/1396.trivial.rst🤖 Generated with Claude Code
https://claude.ai/code/session_012f14GcdYkiWd68e7zAvLhN