Skip to content

Refactor karva_test_semantic for readability and discoverability#684

Merged
MatthewMckee4 merged 3 commits intomainfrom
refactor/test-semantic-cleanup
Apr 15, 2026
Merged

Refactor karva_test_semantic for readability and discoverability#684
MatthewMckee4 merged 3 commits intomainfrom
refactor/test-semantic-cleanup

Conversation

@MatthewMckee4
Copy link
Copy Markdown
Member

@MatthewMckee4 MatthewMckee4 commented Apr 15, 2026

Summary

Readability refactors across karva_test_semantic, no behaviour change. classify_test_result loses its eleven-argument signature and three-level nested match in favour of a small VariantReportCtx struct with early returns. The functions/ module now follows the same mod.rs barrel + python.rs PyO3 surface convention as tags/ and fixtures/. Python interpreter attachment moves out of utils.rs into a new src/py_attach.rs with attach_with_output replacing the misnamed attach_with_project.

Test plan

ci

Consolidate the PyO3 surface, simplify the test-variant classification
logic, and extract the Python interpreter attachment helpers out of
`utils.rs` into their own module.
@MatthewMckee4 MatthewMckee4 added the internal An internal refactor or improvement label Apr 15, 2026
@codspeed-hq
Copy link
Copy Markdown

codspeed-hq bot commented Apr 15, 2026

Merging this PR will not alter performance

⚠️ Unknown Walltime execution environment detected

Using the Walltime instrument on standard Hosted Runners will lead to inconsistent data.

For the most accurate results, we recommend using CodSpeed Macro Runners: bare-metal machines fine-tuned for performance measurement consistency.

✅ 1 untouched benchmark


Comparing refactor/test-semantic-cleanup (87097fe) with main (2f2b75d)

Open in CodSpeed

@MatthewMckee4 MatthewMckee4 merged commit faef1bf into main Apr 15, 2026
11 checks passed
@MatthewMckee4 MatthewMckee4 deleted the refactor/test-semantic-cleanup branch April 15, 2026 15:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

internal An internal refactor or improvement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant