Skip to content

fix: mismatched test case correlation for some rules#32

Merged
boidolr merged 2 commits into
mainfrom
dev
Mar 8, 2026
Merged

fix: mismatched test case correlation for some rules#32
boidolr merged 2 commits into
mainfrom
dev

Conversation

@boidolr

@boidolr boidolr commented Mar 8, 2026

Copy link
Copy Markdown
Owner
  • fix: more informative overall status check
  • fix: handle ty errors with special characters

Copilot AI review requested due to automatic review settings March 8, 2026 10:41
@boidolr boidolr changed the title fix: mismatched test case correlation for some rules' fix: mismatched test case correlation for some rules Mar 8, 2026
@boidolr boidolr merged commit 1f9b359 into main Mar 8, 2026
12 checks passed
@boidolr boidolr deleted the dev branch March 8, 2026 10:42

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pull request overview

This PR updates the pytest-ty plugin’s diagnostic handling to better correlate ty failures with individual test files and to surface a more informative overall status when multiple files fail.

Changes:

  • Switch ty check invocation to a structured output format and parse diagnostics via JSON instead of splitting colon-delimited strings.
  • Improve the status item error output to include all diagnostic messages (not just file keys).
  • Extend tests to cover multiple failing files and a failure case involving diagnostics that previously risked parsing issues.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.

File Description
tests/test_pytest_ty.py Adds fixtures and new assertions to ensure multiple-file failures and parsing-sensitive diagnostics are correctly attributed and reported.
src/pytest_ty/plugin.py Changes ty output format, parses JSON diagnostics into per-file errors, and improves status aggregation output.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread tests/test_pytest_ty.py
Comment thread tests/test_pytest_ty.py
Comment thread src/pytest_ty/plugin.py
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.

2 participants