Repository navigation
test(change-risk): pin that a filtered call shares the early test selection - #5053
Merged
Merged
Conversation
…ection The test selection that starts beside the score reads the whole commit, as the tests block does: the request's exclude_patterns, extensions and include_paths narrow the score, not the tests' change. Each filter now runs through the existing head-start test with a commit the filter narrows, and the call must still select tests from one run.
swati510
approved these changes
Oct 30, 2026
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.
get_change_risk starts the test selection beside the score for a named commit or range, and the tests block joins it. The tests block reads the whole commit (only repowise's own output is left out), so the request's
exclude_patterns,extensionsandinclude_pathsnarrow the score but not the tests' change, and a filtered call shares the early selection.No test pinned that for filtered calls. The existing head-start test now runs once per filter, with a commit the filter narrows, and must still select tests from a single selection run. If either side of the change ever started honoring the filters alone, the two changes would differ and the test would see two runs.
Cold filtered calls on current main, one process each (
impacted_testspresent, selection runs):docs/.pypackages/*.test.ts.tssrc/middleware/No call returned busy or timeout. ("degraded" is an index that lags the checkout; "run_all" on hono comes from its config.)
Verification:
tests/unit/server/mcp/test_change_test_selection.py,tests/unit/change_health/test_mcp_contract.py(44 passed), top-leveltests/unit/*.py(1901 passed),ruff check .,repowise health check origin/main...HEADpassed.