Skip to content

PYTHON-6052 - Fix TEST_ARGS splitting in coverage runs - #3007

Merged
NoahStapp merged 1 commit into
mongodb:mainfrom
NoahStapp:PYTHON-6052
Aug 25, 2026
Merged

PYTHON-6052 - Fix TEST_ARGS splitting in coverage runs#3007
NoahStapp merged 1 commit into
mongodb:mainfrom
NoahStapp:PYTHON-6052

Conversation

@NoahStapp

Copy link
Copy Markdown
Contributor

PYTHON-6052

Changes in this PR

See ticket.

Test Plan

N/A

Checklist

Checklist for Author

  • Did you update the changelog (if necessary)?
  • Is there test coverage?
  • Is any followup work tracked in a JIRA ticket? If so, add link(s).

Checklist for Reviewer

  • Does the title of the PR reference a JIRA Ticket?
  • Do you fully understand the implementation? (Would you be comfortable explaining how this code works to someone else?)
  • Is all relevant documentation (README or docstring) updated?

@NoahStapp
NoahStapp requested a review from a team as a code owner August 25, 2026 16:39
@NoahStapp
NoahStapp requested review from blink1073 and a lite review from Copilot August 25, 2026 16:39

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Fixes how TEST_ARGS are passed when running tests under coverage in Evergreen so that arguments containing spaces (e.g., marker expressions constructed by handle_green_framework()) are not broken by string/shell-style splitting.

Changes:

  • Removes shlex-based command construction for coverage runs and passes argv as a list to subprocess.run.
  • Updates coverage execution to run coverage run -m pytest with TEST_ARGS and sys.argv[1:] preserved as distinct argv items.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread .evergreen/scripts/run_tests.py
@codecov

codecov Bot commented Aug 25, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@NoahStapp
NoahStapp requested review from sleepyStick and removed request for blink1073 August 25, 2026 17:45
@NoahStapp
NoahStapp merged commit 9bf9802 into mongodb:main Aug 25, 2026
87 of 90 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants